Displaying 20 results from an estimated 20000 matches similar to: "viewing data in something similar to 'R Data Editor'"
2006 May 16
2
retaining character matrices when combining into data frames
Hello everyone,
If I want to convert or combine a (large) character matrix into a data
frame without having any of its columns convert into a factor class,
is there a simple solution? I() says it will operate on 'an
object' but it seems that unless the object is a vector, the results
are not what I expect.
For instance, if g is a 2x2 character matrix, as.data.frame(I(g)) will
return an
2010 Sep 05
1
Greek symbols (again but more complicated)
Hi.
I'm trying to get 'mu' to show up as a Greek symbol but, despite trying every example I could find, can't get it to work. Any insights would be welcome.
This is what I'm using that works, but displays mu with the letter u.
plotTimeXMastPAR <- qplot(DT,MastPAR, data=A, xlab = "", ylab = quote(PAR (uE ~m^-2 ~s^-1)), geom="line") +
2011 Sep 07
3
Editing the variables attributes section in the netCDF header of netCDF files created using the package ncdf.
Hi,
I am using the package ncdf to create netCDF files and I want to mimic the the header of an exiting netCDF file created outside of R. Below is what the existing header looks like (part of it that is different):
netcdf ccd1984_05_08 {
dimensions:
lat = 1974 ;
lon = 1894 ;
time = UNLIMITED ; // (1 currently)
variables:
int time(time) ;
2016 Apr 22
2
Unexpected values obtained when reading in data using ncdf and ncdf4
Dear R Users,
I am encountering a problem when reading nc files into R using the ncdf and ncdf4 libraries. The nc files are too large to attach an example (but if someone is interested in helping out I could send a file privately via an online drive), but the code is basic:
for(i in 1:length(thesenames[,1])){
data <- nc_open(paste(INDIR, thesenames[i,c("wholename")],
2011 Sep 12
1
Problem in put.var.ncdf
Dear all,
I have a problem in writing a variable to a NetCDF-File.
My code works pretty well until the step put.var.ncdf():
# Get variables
#---------------------
data1 <- open.ncdf("PREC_me_03-1500.nc")
prec1 <- get.var.ncdf(data1,"PRECT")
dim.time <- get.var.ncdf(data1,"time2")
close.ncdf(data1)
# Calculation
#---------------------
spi24.me <-
2011 Jan 14
3
RSQLite - How to express(or save) a dataframe as an output?
Dear R helpers
Suppose following is an output due to some R process. I wish to save it as a table in 'temp.db'
df <- data.frame(x = c(5, 4, 3, 11), y = c(25, 16, 9, 121))
library(RSQLite)
write('** Initializing','')
drv <- dbDriver("SQLite", shared.cache = TRUE)
con <- dbConnect(drv, dbname = "temp.db",
2010 Sep 23
1
NetCDF file: adding a variable
I am trying to create a NetCDF file with bathymetry (a matrix) and then to
add a grid type (an integer) as variables.
This is the relevant part of the code:
library(ncdf)
wfile="my_file.nc"
msv=-10
grdtp=2
# Dimensions
d1=dim.def.ncdf("lon","degrees",as.double(lon))
d2=dim.def.ncdf("lat","degrees",as.double(lat))
# Variables
2017 Sep 07
1
extend limited dimension in netcdf
Dear all
I have to combine 3D netCDF files (lon, lat, time). The files contain data of one month and I need a year file containing all the data. Because the attributes of all files are the same, I copied the first file and appended the data of the other months. This went well until the provider of the data changed the time-dimension from UNLIMITED to LIMITED. Is there a way to change the time
2010 Oct 26
1
ncdf4 package installation in R
Hello all,
I could use some help installing the ncdf4 package in R (under CentOS 5.4).
I've installed R-2.12.0, zlib-1.2.5, hdf5-1.8.4-patch1 and NetCDF4.1.1 from
source. Make check reports all tests have passed for all of these programs.
When I issue an 'install.packages(c('ncdf4')) in R, compilation succeeds but
I receive the following error during the loading phase of
2011 May 10
1
Reading a large netCDF file using R
I got a netCDF file from a climate group and wanted to aggregate the data.
The file summary looks like this
library(ncdf)
nc=open.ncdf("NCEP_prec_1949_58.nc")
> nc
[1] "file NCEP_prec_1949_58.nc has 4 dimensions:"
[1] "Time Size: 14608"
[1] "lat Size: 99"
[1] "lon Size: 199"
[1] "DateStrLen Size: 20"
[1]
2012 Jan 03
1
where to ask questions regarding package=ncdf?
Should one ask questions relating to the R package 'ncdf' here? or
look for a more netCDF-oriented (but probably less R-oriented) list?
Why I ask:
I'm relatively new to R, which I've only used in the past for graphics.
I'm trying to learn R as an alternative to manipulating netCDF files
with NCO (which works well but lacks all the other R goodnesses). Hence
I've got a
2011 Jan 12
2
RNetCDF: retrieving variable names and units
Dear List,
does anybody has experience with the RNetCDF package? I manage to open a connection and copy data from a ncdf file but would need a way to automatically retrieve variable names (ideally all of them from one file) and units from the file.
Any ideas?
Jannis
2012 Apr 02
2
how to read netcdf file in R
Dear R Users,
I am using R 2.14.1 on windows
How to read netcdf files in R ?
Which packeges do we need to install for this,
and what commands are used for reading netcdf files.
Thanks,
Best Regards,
Yogesh Tiwari
--
Yogesh K. Tiwari (Dr.rer.nat),
Scientist,
Centre for Climate Change Research,
Indian Institute of Tropical Meteorology,
Homi Bhabha Road,
Pashan,
Pune-411008
INDIA
Phone:
2016 Apr 22
0
Unexpected values obtained when reading in data using ncdf and ncdf4
On Fri, Apr 22, 2016 at 1:32 AM, Louise Mair <louise.mair at slu.se> wrote:
> Dear R Users,
>
> I am encountering a problem when reading nc files into R using the ncdf
> and ncdf4 libraries. The nc files are too large to attach an example (but
> if someone is interested in helping out I could send a file privately via
> an online drive), but the code is basic:
>
?[...]?
2017 Aug 14
2
ncdf4: Why are NAs converted to _FillValue when saving?
Dear all
I'm a newbie regarding netcdf data. Today I realized that I maybe do not understand some basics of the netcdf. I want to create a *.nc file containing three variables for Switzerland. All data outside of the country are NAs. The third variable is calculated from the first two variables. Basically there is no problem to do that. I copy the file with the data of the first variable,
2011 Jul 07
1
Select element out of several ncdf variables
Hi there
I'm working with ncdf data. I have different dataset for 4 runs, 4 seasons
and 3 timeslices (48 datasets in total). The datasets have the following
dimensions: 96 longitudes, 48 latitudes and 30 time steps. To read all of
them in, I wrote the following loop:
runs <- c("03","04","05","06")
years <- c(1851,1961,2061)
seasons <-
2011 Dec 12
2
i can't read large NETCDF file like CRU
i use library(ncdf) to read this file as follow
library(ncdf)
sst.nc = open.ncdf(title)
lonall = get.var.ncdf(sst.nc,'lon')
latall = get.var.ncdf(sst.nc,'lat')
precip = get.var.ncdf(sst.nc,'pre')
close(sst.nc)
if i use this method my pc freeze and not respond until i restart it is
there
--
View this message in context:
2011 Mar 21
1
Lat Lon NetCDF subset
Hi,
I'm trying to read a subset of a netcdf file into R, but although I'm
relatively experienced using R, I'm still new to netCDF files, so this may
be a very simple/stupid question!
I've included an example of the type of file I'm looking at here.
www.met.reading.ac.uk/~swp06hg/ccd1983_01-dk1_20.nc (~7Mb)
It's a 2D array of the variable CCD along with its lat and
2011 May 06
1
read a netcdf file _Fill_value=-32768
Hello
I am a new user of R .
and I ve problem with R and netcdf .
I succed installation , I could use all examples .
But when I take my netcf it is different .
I want to do statistic on this kind of file .
1)
first calculate mean .
my data is like that
through ncdump -h test.nc
netcdf test {
dimensions:
lat = 301 ;
lon = 401 ;
time = UNLIMITED ; // (80 currently)
2007 Aug 28
4
Nodes & edges with similarity matrix
Hello,
I apologise if someone has already answered this but I searched and
googled but didn't find anything.
I have a matrix which gives me the similarity of each item to each
other. I would like to turn this matrix into something like what they
have in the graph package with the nodes and edges.
http://cran.r-project.org/doc/packages/graph.pdf . However I cannot find
a method to