[37] | 1 | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" |
---|
| 2 | "http://www.w3.org/TR/REC-html40/loose.dtd"> |
---|
| 3 | <html> |
---|
| 4 | <head> |
---|
| 5 | <title>Description of read_ncvar</title> |
---|
| 6 | <meta name="keywords" content="read_ncvar"> |
---|
| 7 | <meta name="description" content="'read_ncvar': reads a list of fields and constants in a netcdf file"> |
---|
| 8 | <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> |
---|
| 9 | <meta name="generator" content="m2html © 2003 Guillaume Flandin"> |
---|
| 10 | <meta name="robots" content="index, follow"> |
---|
| 11 | <link type="text/css" rel="stylesheet" href="../../../../m2html.css"> |
---|
| 12 | </head> |
---|
| 13 | <body> |
---|
| 14 | <a name="_top"></a> |
---|
| 15 | <div><a href="../../../../index.html">Home</a> > <a href="#">coriolis</a> > <a href="#">bigone</a> > <a href="#">PROJETS</a> > <a href="#">UVMAT.new</a> > read_ncvar.m</div> |
---|
| 16 | |
---|
| 17 | <!--<table width="100%"><tr><td align="left"><a href="../../../../index.html"><img alt="<" border="0" src="../../../../left.png"> Master index</a></td> |
---|
| 18 | <td align="right"><a href="index.html">Index for /coriolis/bigone/PROJETS/UVMAT.new <img alt=">" border="0" src="../../../../right.png"></a></td></tr></table>--> |
---|
| 19 | |
---|
| 20 | <h1>read_ncvar |
---|
| 21 | </h1> |
---|
| 22 | |
---|
| 23 | <h2><a name="_name"></a>PURPOSE <a href="#_top"><img alt="^" border="0" src="../../../../up.png"></a></h2> |
---|
| 24 | <div class="box"><strong>'read_ncvar': reads a list of fields and constants in a netcdf file</strong></div> |
---|
| 25 | |
---|
| 26 | <h2><a name="_synopsis"></a>SYNOPSIS <a href="#_top"><img alt="^" border="0" src="../../../../up.png"></a></h2> |
---|
| 27 | <div class="box"><strong>function [cte_detect,var_detect,cte_read,var_read,choice,cte2_detect,var2_detect,cte2_read,var2_read,choice2]=read_ncvar(filename,cte1,nb1,var1,cte2,nb2,var2) </strong></div> |
---|
| 28 | |
---|
| 29 | <h2><a name="_description"></a>DESCRIPTION <a href="#_top"><img alt="^" border="0" src="../../../../up.png"></a></h2> |
---|
| 30 | <div class="fragment"><pre class="comment">'read_ncvar': reads a list of fields and constants in a netcdf file |
---|
| 31 | ------------------------------------------------------------------ |
---|
| 32 | [cte_detect,var_detect,cte_read,var_read,choice,cte2_detect,var2_detect,cte2_read,var2_read]=... |
---|
| 33 | read_netcdf(filename,cte1,nb1,var1,cte2,nb2,var2,option) |
---|
| 34 | OUTPUT: |
---|
| 35 | cte_detect: array with the dimension of cte1 or cte2 (option 'or'), =1 if the constant is detected 0 else. |
---|
| 36 | var_detect: like cte_detect for the variables |
---|
| 37 | cte_read: list of the values for the constants (global attributes), =0 if not detected |
---|
| 38 | var_read(ind,:): variable array number ind, the variable #i is determined as var_read(ind(i),:), with ind=cumsum(var_detect); |
---|
| 39 | choice=1 if the first list is chosen (or with the option 'and'), 2 else. |
---|
| 40 | cte2_detect,var2_detect, cte2_read,var2_read, second set of v ctes and variables (only with the option 'and') |
---|
| 41 | |
---|
| 42 | INPUT: |
---|
| 43 | filename (netcdf file) |
---|
| 44 | cte1: cell array listing the constants (global attributes) to read |
---|
| 45 | nb1: name the constant in the netcdf file giving the length of var1 (if absent no variable is read) |
---|
| 46 | if nb1 is a cell array, nb1{i} corresponds to the choice by order of priority (as given by varname_generator) |
---|
| 47 | and cte{i,:} is the corresponding list of constants |
---|
| 48 | var1{i,:}: list of variables arrays to read by order of priority with length nb1{i} |
---|
| 49 | cte2,nb2,var2: second list of cte and variables (optional) |
---|
| 50 | |
---|
| 51 | related FUNCTION |
---|
| 52 | 'varname_generator.m': generates the appropriate list of variables and constants</pre></div> |
---|
| 53 | |
---|
| 54 | <!-- crossreference --> |
---|
| 55 | <h2><a name="_cross"></a>CROSS-REFERENCE INFORMATION <a href="#_top"><img alt="^" border="0" src="../../../../up.png"></a></h2> |
---|
| 56 | This function calls: |
---|
| 57 | <ul style="list-style-image:url(../../../../matlabicon.gif)"> |
---|
| 58 | <li><a href="nc2struct.html" class="code" title="function [Data,var_detect,ichoice]=nc2struct(nc,ListVarName)">nc2struct</a> 'nc2struct': transform a netcdf file in a corresponding matlab structure</li></ul> |
---|
| 59 | This function is called by: |
---|
| 60 | <ul style="list-style-image:url(../../../../matlabicon.gif)"> |
---|
| 61 | <li><a href="read_ncdata.html" class="code" title="function [Field,VelTypeOut]=read_ncdata(filename,FieldNames,VelType);">read_ncdata</a> 'read_ncdata': reads variables from netcdf files, recognizing civx data.</li><li><a href="read_ncfield.html" class="code" title="function [nb_coord,nb_dim,Civ,CivStage,time,Field,VelTypeOut,Calib]=read_ncfield(filename,VelType,ScalDisplay,ScalName);">read_ncfield</a> 'read_ncfield': reads one or two velocity fields and associated parameters from a file .</li></ul> |
---|
| 62 | <!-- crossreference --> |
---|
| 63 | |
---|
| 64 | |
---|
| 65 | |
---|
| 66 | <hr><address>Generated on Tue 14-Apr-2009 22:21:41 by <strong><a href="http://www.artefact.tk/software/matlab/m2html/">m2html</a></strong> © 2003</address> |
---|
| 67 | </body> |
---|
| 68 | </html> |
---|