<div dir="ltr"><div dir="ltr"><div dir="ltr"><div>I am blissfully ignorant about using JSON and <span style="color:rgb(255,0,0)"><b>I prefer to stay that way! :-)</b></span></div><div><b></b><br></div><div>There are some negative comments about using JSON for "configuration files."<br></div><div dir="ltr"><br></div><div><b>Note:</b><br></div><div dir="ltr"><a href="https://arp242.net/weblog/json_as_configuration_files-_please_dont"><b>https://arp242.net/weblog/json_as_configuration_files-_please_dont</b></a></div><div dir="ltr"><a href="https://revelry.co/json-configuration-file-format/"><b>https://revelry.co/json-configuration-file-format/</b></a></div><div dir="ltr"><b>=================================================</b></div><div>That said, NCL 6.5.0 has the following which can be used to read an 'NCL configuration' file.</div><div><br></div><div><a href="https://www.ncl.ucar.edu/Document/Functions/Contributed/keyword_values.shtml"><b>https://www.ncl.ucar.edu/Document/Functions/Contributed/keyword_values.shtml</b></a></div><div><br></div><div>If you do:</div><div><br></div><div><b>%></b> less <b>$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl</b></div><div><br></div><div>and search for "<b>keyword_values</b>" you can see the code. If you find this useful, you could extract the function code and, perhaps, tune it to your needs.</div><div><br></div><div>An advantage of the NCL "<b>keyword_values</b>"is that it does allow comments to be embedded within the configuration file.</div><div><br></div><div>Good luck</div><div>D<br></div><div><br></div><div><br></div><div><br></div></div></div></div><br><div class="gmail_quote"><div dir="ltr">On Wed, Oct 10, 2018 at 8:37 AM Francesco Trotta <<a href="mailto:francesco.trotta4@unibo.it">francesco.trotta4@unibo.it</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div id="m_6570012986600309115divtagdefaultwrapper" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif" dir="ltr">
<p>ok, I tried to implement a procedure using asciiread and ncl string manag. functions. to read the json</p>
<p><br>
</p>
<p>but I think this feature will be useful to be implement in NCL package</p>
<p>because json are now very common as configuration file </p>
<p><br>
</p>
<p>thanks</p>
<p>Fra</p>
</div>
<hr style="display:inline-block;width:98%">
<div id="m_6570012986600309115divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>Da:</b> Rick Brownrigg <<a href="mailto:brownrig@ucar.edu" target="_blank">brownrig@ucar.edu</a>><br>
<b>Inviato:</b> giovedì 4 ottobre 2018 21:36:55<br>
<b>A:</b> Francesco Trotta<br>
<b>Cc:</b> Ncl-talk<br>
<b>Oggetto:</b> Re: [ncl-talk] read json file</font>
<div> </div>
</div>
<div>
<div dir="ltr">
<div>Hi,</div>
<div><br>
</div>
<div>No unfortunately, there is no direct support for reading JSON.</div>
<div><br>
</div>
<div>Rick<br>
</div>
</div>
<br>
<div class="m_6570012986600309115x_gmail_quote">
<div dir="ltr">On Thu, Oct 4, 2018 at 1:04 PM Francesco Trotta <<a href="mailto:francesco.trotta4@unibo.it" target="_blank">francesco.trotta4@unibo.it</a>> wrote:<br>
</div>
<blockquote class="m_6570012986600309115x_gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div dir="ltr">
<div id="m_6570012986600309115x_m_7154662005841051698divtagdefaultwrapper" dir="ltr" style="font-size:12pt;color:#000000;font-family:Calibri,Helvetica,sans-serif">
<p style="margin-top:0;margin-bottom:0">Dear mcl-talk</p>
<p style="margin-top:0;margin-bottom:0"> I'm using ncl 6.4.0.</p>
<p style="margin-top:0;margin-bottom:0"> Is there a way to read JSON file in ncl?</p>
<p style="margin-top:0;margin-bottom:0"> </p>
<p style="margin-top:0;margin-bottom:0">thanks</p>
<p style="margin-top:0;margin-bottom:0">Francesco T.</p>
</div>
</div>
_______________________________________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a><br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" rel="noreferrer" target="_blank">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a><br>
</blockquote>
</div>
</div>
</div>
_______________________________________________<br>
ncl-talk mailing list<br>
<a href="mailto:ncl-talk@ucar.edu" target="_blank">ncl-talk@ucar.edu</a><br>
List instructions, subscriber options, unsubscribe:<br>
<a href="http://mailman.ucar.edu/mailman/listinfo/ncl-talk" rel="noreferrer" target="_blank">http://mailman.ucar.edu/mailman/listinfo/ncl-talk</a><br>
</blockquote></div>