Displaying 20 results from an estimated 900 matches similar to: "How can I map numbers to colours with raster?"
2020 Feb 19
2
Pregunta sobre rLandsat
Hola grupo, estoy siguiendo una gu?a de la librer?a rLandsat que me la he descargado de:
devtools::install_github("socialcopsdev/rLandsat")
Y tras hacer los siguiente (obviamente tengo me he registrado previamente en la api correspondiente):
product_id = c("LC08_L1TP_145049_20180301_20180308_01_T1",
"LC08_L1TP_145049_20170330_20170414_01_T1",
2020 Feb 20
3
Pregunta sobre rLandsat
Hola Ángel:
Yo creo que tendrías que establecer el sistema de coordenadas de
referencia de tu objeto raster antes de salvarlo como GTiff. Algo así:
crs(r1) <-"+proj=utm +zone=14 +datum=WGS84"
Saludos,
Marcelino.
El 20/02/2020 a las 1:42, Angel Cervantes escribió:
> Hola a todos, quisiera pedirles su ayuda. Estoy tratando de crear un raster a partir de una tabla de datos
2012 Feb 28
1
colour by z value, persp in raster package
Hi all!
My question is how to colour pixels by z value in persp plot in raster package. Here is an example:
x <- seq(-1.95, 1.95, length = 30)
y <- seq(-1.95, 1.95, length = 35)
z <- outer(x, y, function(a,b) a*b^2)
r1 <- raster(nrows=35, ncols=30, xmn=0, xmx=30, ymn = 0, ymx = 35)
r1[] <- c(z)
persp(r1)
There already exist some function to produce persp plot for anothe
2012 Aug 08
1
Adjusting coordinates in raster plots
Dear R-Help,
When plotting a raster object the origin (0,0) is placed in the center.
E.g. using:
library(raster)
mat = matrix(runif(100),10,10)
r <- raster(ncol=10, nrow=10)
values(r) <- mat
plot(r, main='Raster example',xlab="x",ylab="y")
Does anyone know how to adjust the coordinate system?
E.g. I would like to have 0,0 at the top left.
My naive approach
2013 Mar 04
1
How to loop several binary files from two directories?
I have two binary files(rasters) with the same dimensions. The first file is
called `over` and the second is `corr`. I want to replace values in `over`
by `NA` whenever `corr` is greater than 0.5.
to read the two files we can use:
conne <- file("C:corr.bin","rb")
over <- readBin(conne, numeric(), size=4, n=1440*720, signed=TRUE)
frf <-
2012 Jun 20
1
Edges and Rasters
Hi everyone!
I would like to draw a line surrounding my raster, with i want it in black,
and i don't know if its possible to change the colour.
A simple example is:
r <- raster(nrow=30, ncol=30, xmn=0)
r[]<-NA
r[393:409]<-99
r[423:439]<-99
r[453:455]<-99
r[456:460]<-30
r[461:469]<-99
r[483:499]<-99
r[513:529]<-99
plot(r,col=terrain.colors(100))
plot( edge(r,
2012 May 24
6
R does not recognise columns and rows as they are supposed to be
Dear All,
The code given bellow is to extract values of one region and write that to
a text file(there are 365 binary files in the directory).
The problem which I am facing is that all my files are binary with size of
360 rows and 720 columns.
I specified that in this line: file2<-matrix(data=file,ncol=720,nrow=360)
but I got an error : Error in mean(file2[X, Y], na.rm = TRUE) : subscript
2012 Apr 06
2
read multiaple files within one folder
Suppose we have files in one folder file1.bin, file2.bin, ... , and
1460slice(file) with dim of 720 * 360 in directory C:\\PHD\\Climate
Data\\Wind\\ and we want to read them and make a loop to go from 1 to 4
and take the average, then from 4 to 8 and so on till 1460. in the end we
will get 365 files . I need those 365 files to be in one new folder for
later use in my model
I tried using this
2013 Jan 14
4
How to open grib file in R?
I have this https://echange-fichiers.inra.fr/get?k=6TdTdezNeZwAqJtpwVm
grib file which is a regular lat-lon 0.25x0.25 degrees and contains 4 fields
.
I tried to open it using :
grib <-
readGDAL("C:\\Users\\aalyaari\\Desktop\\Vol_025_H14_2010060700.grib")
but I got this error:
C:\Users\aalyaari\Desktop\Vol_025_H14_2010060700.grib has GDAL driver GRIB
and has 721 rows and
2004 Jun 06
3
Average R-squared of model1 to model n
Hi,
We got a question about interpretating R-suqared.
The actual outputs for a test dataset is X=(x1,x2, ..., xn).
model 1 predicted the outputs as Y1=(y11,y12,..., y1n)
model n predicted the outputs as Y2=(y21,y22,..., y2n)
...
model m predicted the outputs as Ym=(ym1,ym2,..., ymn)
Now we have two ways to calculate R squared to evaluate the average performance of committee model.
(a)
2005 Sep 19
6
Teaching R - In front of the computer?
Dear R-Users,
given you have been teaching R to students (grad level, mainly social
science background, no previous programming experience, 80% know SPSS),
what are your experiences concerning the style of teaching? Do you
prefer to stand in front of the class like in "normal" lectures and you
show them slides? Or do you you explain some concept (for example things
like
2012 Jun 13
1
How to calculate the statistcs for extracted region?
I have a binary file(a) with size of (360 720 )for the globe.I wrote the code
given below to read and extract an area (south america)from that file. when
I use summary for the whole file I got:
summary(a, na.rm=FALSE)
Min. 1st Qu. Median Mean 3rd Qu. Max. NA's
0.00 1.00 3.00 4.15 7.00 20.00 200083 .
But when I used summary for the region(b) which I extracted, I got
2010 Mar 07
2
CentOS server running java - won't let go of swap
I'm monitoring some CentOS 5 servers running Sun Java. We have set things
up so 2048 MB of RAM are available for the base operating system, taking
into account the xMx and permgen settings. What we're seeing is the swap
space getting used up, and not released. Is this normal behavior?
Performance doesn't seem to be affected, however I'm a bit concerned that
the swap file is
2006 Jan 10
2
standardized residuals (rstandard & plot.lm) (PR#8468)
This bug is not quite fixed - the example from my original report now =
works using R-2.2.1, but
plot(Uniform, 6)
does not. The bug is due to
if (show[6]) {
ymx <- max(cook, na.rm =3D TRUE) * 1.025
g <- hatval/(1 - hatval) # Potential division by zero here #
plot(g, cook, xlim =3D c(0, max(g)), ylim =3D c(0, ymx),=20
main =3D main, xlab =3D
2012 Dec 31
1
(no subject)
Dear useRs,
I am getting following error while using my R java machine.
>Error: OutOfMemoryError (Java): Java heap space
to get rid of it i used
>options( java.parameters = "-Xmx1200m")
but unfortunatly its not working....
Does anyone ever encountered this error??
thanks in advance...
elisa
[[alternative HTML version deleted]]
2010 Jun 15
3
Newbie trying to set up rails with MySQL
Hello --
Please pardon my newness -- I''m just getting started with rails, and
I''m having some difficulty getting it set up with MySQL.
I am able to get the basic ruby server running (script\server). When I
created a new page (using script/generate controller about index), I
am not able to navigate to the new page, and Ruby either crashes or
gives me an error:
/!\ FAILSAFE /!\
2013 Jan 18
2
How to re-project ease( Equal Area Scalable Earth) grid with a ~25 km cylindrical projection to WGS84 0.25 degree?
I have nc files for global soil moisture,here is one file
https://echange-fichiers.inra.fr/get?k=f9DDllPKdUKs5ZNQwfq
from the metadata ,the projection is cylindrical and the resolution is 25
km(it is based on authalic sphere based on International 1924 ellipsoid).As
I want to compare with other data, I have to make them identical.
- my other data are in WGS84 with 0.25*0.25 degree resolution
2008 Mar 30
1
Can't find matching timezone
Hello Folks.
I am spending some time trying to run AutoCad 2004. I fixed a lot of errors about .dll and some .xmx files (needed to run autocad) and everything is ok. But now, I can not pass by this error:
fixme:ntdll:find_reg_tz_info Can't find matching timezone information in the registry for bias 180, std (d/m/y): 17/02/2008, dlt (d/m/y): 12/10/2008
How do i fix the registry? I tried to
2011 Feb 03
1
ADS 2008 configuration
Hi,
I am Inderjit, and have some issues with configuration of samba with ADS 2008.
I am able to connect to ADS 2008, but command "getent group" doesn't show always the output with ADS groups. We have more that 25000 users and domain controller is not located at same location.
Could you please give me a hints or suggestions, what can be changed to solve this issue.
Regards
2006 Feb 01
1
akima 0.4-5, interpp() bug = COMMON block problem
Hi,
I'm currently hunting a bug in the akima library, especially in the code
behind the interpp.old function (bi-variate linear interpolation).
It is based on a triangulation algorithm, interpolation at a given point
needs to know the triangle which contains this point, then the
interpolation is a straightforward calculation based on the three
vertexes.
The problem is: Sometimes the triangle