ncap2: dimension not available to nco_var_fll

Developers
Stubaan
2012-05-14
2013-10-17
  • Stubaan
    Stubaan
    2012-05-14

    Folks,

    I have a file containing 3 variables:

    prcp_template(time,z,latitude,longitude)
    pr(latitude,longitude)
    pr_past_proj(latitude,longitude)

    I am trying to execute the following:

    ncap2 -h -A -v -s 'pr_ratio=pr/pr_past_proj' -s 'pr_future=prcp_template*pr_ratio' "$inpath"/"$infile" "$outpath"/"$outfile"

    I am getting the following error:

    ncap2: ERROR dimension latitude is not in list of dimensions available to nco_var_fll()
    ncap2: HINT This could be a symptom of TODO nco111. Workaround is to make sure each dimension in the weighting and masking variable(s) appears in a variable to be processed.

    If you examine the file (link below) you will see that latitude is definitely present in all the variables.  The pr and pr_past_proj variables have no z or time dimension (the latter was degenerate and I removed it via ncwa after averaging).

    Note that I originally had -s 'pr_future=prcp_template*pr/pr_past_proj" and received this similar, but different, error:

    ncap2: ERROR dimension time is not in list of dimensions available to nco_var_fll()
    ncap2: HINT This could be a symptom of TODO nco111. Workaround is to make sure each dimension in the weighting and masking variable(s) appears in a variable to be processed.

    Any insight into what this means and how to resolve this would be helpful. The file can be downloaded from https://sourceforge.net/projects/ipcc3hourly/files/NCO%20ncap2/

     
  • Stubaan
    Stubaan
    2012-05-14

    My apologies: I see I posted this to the Developers forum instead of the Open Discussion forum.

    Is it possible to delete a post? I cannot seem to find such an option…

     
  • Charlie Zender
    Charlie Zender
    2012-05-14

    This command works fine for me with recent ncap2 versions on Ubuntu.
    The -A switch may be causing the problems.
    Suggest you drop it.

    zender@roulee:~$ /usr/bin/ncap2 -O -h -v -s 'pr_ratio=pr/pr_past_proj' -s 'pr_future=prcp_template*pr_ratio' ~/G_2001_01.nc ~/foo.nc
    zender@roulee:~$ /usr/bin/ncap2 -version
    NCO netCDF Operators version "4.1.0" last modified 2012/03/12 built Mar 29 2012 on roulee by zender
    ncap2 version 20120514

     
  • Charlie Zender
    Charlie Zender
    2012-05-14

    There is no way to delete a post that I know of.
    We read all the posts so there'sno need to repost.
    but your right, the other forum is more appropriate,
    so post followups there.