Hi Now I am using netcdfSubset and I am able to download the file but not sure how to read the files. here my scripts library("ncdf4")
gribfile<-" http://thredds.ucar.edu/thredds/ncss/grib/NCEP/GFS/Pacific_40km/best/dataset.html " download.file(gribfile,basename(gribfile),mode = "wb") x<-nc_open(gribfile) gribfile<-" http://thredds.ucar.edu/thredds/ncss/grib/NCEP/GFS/Global_0p5deg/best?north=47.0126&west=-114.841&east=-112.641&south=44.8534&time_start=present&time_duration=PT3H&accept=netcdf&var=v-component_of_wind_height_above_ground,u-component_of_wind_height_above_ground" download.file(gribfile,basename(gribfile),mode = "wb") x<-nc_open(gribfile) nc_open doesn't work. which command should I use? with regards -Deb On Tue, Sep 27, 2016 at 9:30 PM, Michael Sumner <mdsum...@gmail.com> wrote: > Opendap won't work on Windows CRAN build of ncdf4, though the rgdal build > does work directly on grib. > > Summary: download the files wholus for use on Windows, or set your own > system on Linux. > > Building ncdf4 on Windows is not too hard if you know about doing that. > > Cheers, Mike > > On Wed, 28 Sep 2016, 06:49 Roy Mendelssohn - NOAA Federal < > roy.mendelss...@noaa.gov> wrote: > >> Please post the code of what you tried, as I have no idea otherwise what >> did or did not work for you. >> >> -Roy >> >> > On Sep 27, 2016, at 12:44 PM, Debasish Pai Mazumder <pai1...@gmail.com> >> wrote: >> > >> > Hi Roy, >> > Thanks for your response. I have tried according your suggestion but it >> doesn't work. >> > the OPeNDAP link of the data >> > http://nomads.ncdc.noaa.gov/thredds/dodsC/modeldata/cfsv2_ >> forecast_ts_9mon/2014/201404/20140403/2014040312/ >> > >> > datafile: >> > tmax.01.2014040312.daily.grb2 >> > >> > Thanks >> > -Deb >> > >> > On Tue, Sep 27, 2016 at 11:51 AM, Roy Mendelssohn - NOAA Federal < >> roy.mendelss...@noaa.gov> wrote: >> > Look at the package ncdf4. You can use an OPeNDAP URL in place of the >> file name to perform subsets., >> > >> > -Roy >> > >> > > On Sep 27, 2016, at 9:06 AM, Debasish Pai Mazumder <pai1...@gmail.com> >> wrote: >> > > >> > > Hi all, >> > > >> > > I would like to access and subset following OpeNDAP files. >> > > server: >> > > http://nomads.ncdc.noaa.gov/thredds/dodsC/modeldata/cfsv2_ >> forecast_ts_9mon/2014/201404/20140403/2014040312/ >> > > >> > > file name: tmax.01.2014040312.daily.grb2 >> > > <http://nomads.ncdc.noaa.gov/thredds/dodsC/modeldata/cfsv2_ >> forecast_ts_9mon/2014/201404/20140403/2014040312/catalog. >> html?dataset=modeldata/cfsv2_forecast_ts_9mon/2014/201404/ >> 20140403/2014040312/tmax.01.2014040312.daily.grb2> >> > > I would like to access and subset the file. Any help will be >> appreciated. >> > > >> > > with regards >> > > -Deb >> > > >> > > [[alternative HTML version deleted]] >> > > >> > > ______________________________________________ >> > > R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see >> > > https://stat.ethz.ch/mailman/listinfo/r-help >> > > PLEASE do read the posting guide http://www.R-project.org/ >> posting-guide.html >> > > and provide commented, minimal, self-contained, reproducible code. >> > >> > ********************** >> > "The contents of this message do not reflect any position of the U.S. >> Government or NOAA." >> > ********************** >> > Roy Mendelssohn >> > Supervisory Operations Research Analyst >> > NOAA/NMFS >> > Environmental Research Division >> > Southwest Fisheries Science Center >> > ***Note new address and phone*** >> > 110 Shaffer Road >> > Santa Cruz, CA 95060 >> > Phone: (831)-420-3666 >> > Fax: (831) 420-3980 >> > e-mail: roy.mendelss...@noaa.gov www: http://www.pfeg.noaa.gov/ >> > >> > "Old age and treachery will overcome youth and skill." >> > "From those who have been given much, much will be expected" >> > "the arc of the moral universe is long, but it bends toward justice" >> -MLK Jr. >> > >> > >> >> ********************** >> "The contents of this message do not reflect any position of the U.S. >> Government or NOAA." >> ********************** >> Roy Mendelssohn >> Supervisory Operations Research Analyst >> NOAA/NMFS >> Environmental Research Division >> Southwest Fisheries Science Center >> ***Note new address and phone*** >> 110 Shaffer Road >> Santa Cruz, CA 95060 >> Phone: (831)-420-3666 >> Fax: (831) 420-3980 >> e-mail: roy.mendelss...@noaa.gov www: http://www.pfeg.noaa.gov/ >> >> "Old age and treachery will overcome youth and skill." >> "From those who have been given much, much will be expected" >> "the arc of the moral universe is long, but it bends toward justice" -MLK >> Jr. >> >> ______________________________________________ >> R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see >> https://stat.ethz.ch/mailman/listinfo/r-help >> PLEASE do read the posting guide http://www.R-project.org/ >> posting-guide.html >> and provide commented, minimal, self-contained, reproducible code. >> > -- > Dr. Michael Sumner > Software and Database Engineer > Australian Antarctic Division > 203 Channel Highway > Kingston Tasmania 7050 Australia > > [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.