Naresh,
First of all thanks for using reporoducible methods.
I now use knitr instead of Sweave and the switch was fairly trivial. What you
are wanting to do has been supported for a few years within RStudio. I found
https://support.rstudio.com/hc/en-us/articles/200552336-Getting-Help-with-R
2,3] cell of the matrices; do whatever
> you want with them.
>
> Cheers,
> Bert
>
>
>
> Bert Gunter
>
> "The trouble with having an open mind is that people keep coming along and
> sticking things into it."
> -- Opus (aka Berkeley Breathed in his "Bl
I want to capture the entire distribution of values for each cell in a sequence
of symmetric matrices of the same size. The diagonal values are all 0.5 so I
need only the values above or below the diagonal.
A small example with three of the structures I am wanting to count follows:
F
Open the terminal application in the Utilities folder. Select the file you want
to use in R in a Finder window and drag it to the terminal applications command
line prompt and then release the file. The absolute path of the file will be
entered in the command line of the terminal’s window. Thoug
Raffa,
I ran this on a MacOS machine and got what you expected. I added a call to
sessionInfo() for your information.
> rm(list=ls())
> N = 3
> xvar <- runif(N, -10, 10)
> e <- rnorm(N, mean=0, sd=1)
> yvar <- 1 + 2*xvar + e
> plot(xvar,yvar)
> lmMod <- lm(yvar~xvar)
> print(summary(lmMod))
Marco,
Always post to the r-help list to have a better chance of finding someone that
can help.
There is a very nice tutorial that you should have found. See
http://geog.uoregon.edu/bartlein/courses/geog490/week04-netCDF.html#create-and-write-a-netcdf-file
Mark
R. Mark Sharp, Ph.D.
Data Scient
Marco,
The error message indicates that nlon*nlat is 420 and that 1378620/420 has a
remainder. For the matrix to form, all rows have to be complete.
I am guessing you have at least one value incorrect among nlon, nlat, t or the
length of fulldatav.
Mark
R. Mark Sharp, Ph.D.
Data Scientist and
I would usually use a function for this. It may not be more R like, but it is
more readable to me. If you want, to keep the columns in a file, you could have
the function initialize itself on the first call.
Mark
R. Mark Sharp, Ph.D.
Data Scientist and Biomedical Statistical Consultant
7526 Mea
8 matches
Mail list logo