[gradsusr] about fprintf command in Ubuntu

Andrew Friedman andfried at gmail.com
Sun Jul 14 17:50:38 EDT 2019


Hi Yared,
To confirm: do you have fprintf installed and in your GADDIR directory? What do you get when you just type ‘fprintf’?
I had originally downloaded it from OpenGrADS cookbooks, but unfortunately that site doesn’t appear to be active anymore.
I am attaching the script in case you don’t have it.
Andrew
-------------- next part --------------
A non-text attachment was scrubbed...
Name: fprintf.gs
Type: application/octet-stream
Size: 3022 bytes
Desc: not available
URL: <http://gradsusr.org/pipermail/gradsusr/attachments/20190714/42d58c73/attachment.obj>
-------------- next part --------------

> On Jul 14, 2019, at 8:08 PM, Yared Godine <yared.godine at amu.edu.et> wrote:
> 
> Dear Andrew thank you for your immediate respond.
> Sorry for window file path I made a mistake on a message but the path was 
> 'fprintf tasmax-273.15  /home/yared/Desktop/yar/tmax1986_1990.csv %g 1'
> 
> and I tried with out '-273.15'
> 'fprintf tasmax /home/yared/Desktop/yar/tmax1986_1990.csv %g 1'
> also the same answer too
> Unknown command: fprintf
> How can fix this?
> 
> thank you
> with best regard
> Yared
> 
> ----- Original Message -----
> From: "Andrew Friedman" <andfried at gmail.com>
> To: "gradsusr" <gradsusr at gradsusr.org>
> Sent: Sunday, July 14, 2019 7:54:24 PM
> Subject: Re: [gradsusr] about fprintf command in Ubuntu
> 
> Hi Yared,
> 
> Just to check: do you get the same error using a simpler invocation of fprintf? Could you try without the ‘-273.15’ and without the Windows file path?
> I’m also wondering if the comma after %g is correct.
> 
> Andrew
> 
>> On 14 Jul 2019, at 17:34, Yared Godine <yared.godine at amu.edu.et> wrote:
>> 
>> Dear all
>> I tried to write the grads output values into ascii file by using
>> the fprintf.gs script in ubuntu. 
>> I tried the following command
>> 
>> Sdfopen file.nc
>> Set lat 8
>> Set lon 37
>> Set t 1 1826 (since the file has 1826 time steps)
>> fprintf tasmax-273.15  C:\Users\user\Desktop\yared\tmax1986_1990.csv  %g, 12 2
>> 
>> when I run this script, I got the following result:-
>>                                   Unknown command: fprintf
>> 
>> What may be the error with this script or command?
>> 
>> waiting for your kind reply
>> 
>> thanking you
>> with best regard
>> 
>> Yared
>> 
>> 
>> -- 
>> ********************************** 
>> Yared Godine Demeke 
>> Msc. in Meteorology 
>> Instructor in Faculty of Meteorology and Hydrology 
>> Water Technology Institute 
>> Arba Minch University 
>> P. O. Box 21, Arba Minch, Ethiopia. 
>> Mobile :-( +251)-916-854-783 
>> :-( +251)-939-171-133 
>> Email:- yared.godine at amu.edu.et & yarukidus2002 at gmail.com 
>> ***********************************************************
>> _______________________________________________
>> gradsusr mailing list
>> gradsusr at gradsusr.org
>> http://gradsusr.org/mailman/listinfo/gradsusr
> 
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr
> -- 
> ********************************** 
> Yared Godine Demeke 
> Msc. in Meteorology 
> Instructor in Faculty of Meteorology and Hydrology 
> Water Technology Institute 
> Arba Minch University 
> P. O. Box 21, Arba Minch, Ethiopia. 
> Mobile :-( +251)-916-854-783 
> :-( +251)-939-171-133 
> Email:- yared.godine at amu.edu.et & yarukidus2002 at gmail.com 
> ***********************************************************
> 
> _______________________________________________
> gradsusr mailing list
> gradsusr at gradsusr.org
> http://gradsusr.org/mailman/listinfo/gradsusr



More information about the gradsusr mailing list