search for: ppt2

Displaying 4 results from an estimated 4 matches for "ppt2".

Did you mean: ppt
2011 Apr 12
1
How to set the dimension of a matrix correctly?
...x=plon,y=plat)pdim <- dim(pgrid) # (10230,2) #plot(pgrid, cex=0.5) lat <- coords[,1] lon <- coords[,2] ppt1 <- ppt[,1:xx[2]] # 1:528 pptpred <- matrix(0,ncol=xx[2],nrow=1) ############# Only test one period data################## ptemp <- ppt1[,3] ll <- which(ptemp>0) ppt2 <- matrix(0,nrow=length(ll),ncol=3) # (lon,lat,ptemp) ppt2[,1] <- lat[ll] # y-axis ppt2[,2] <- lon[ll] # x-axis ppt2[,3] <- ptemp[ll] # ppt pptd <- as.geodata(ppt2) bin1 <- variog(pptd) # plot(bin1) # fig1 bin2 <- variog(pptd,estimator.type="modulus")#...
2011 Jul 27
2
for loop help
..... thanks-Cassie ### label data ### stnid <- dat1[,1] #list of stations lat <- dat1[,2] #latitude of station lon <- dat1[,3] #longitude of station year <- dat1[,4] # data year month <- dat1[,5] #data month ppt <- dat2 #precipiation data #### station's missing zero years ### ppt2 <- matrix(ppt[,which(stnid == '140365')],ncol=1) year2 <- year[which(stnid == '140365')] year2 <- year2[which(duplicated(year2) == FALSE)] month2 <- month[which(stnid == '140365')] ppt3 <- matrix(ppt[,which(stnid == '140405')],ncol=1) year3 <- ye...
2010 Jan 05
3
R matching lat/lon pairs from two datasets?
...V2 V3 1 -123.76 47.82 8 2 -123.75 47.82 11 > data[1:2] V1 V2 1 47.82 -123.76 2 47.82 -123.75 3 47.82 -123.74 4 47.82 -123.73 #Subset of current R code : lat <- data$V1 lon <- data$V2 yrs <- c(1,2,5,10,25,50,100,200,500,1000) lon2 <- data2$V1 lat2 <- data2$V2 ppt2 <- data2$V3 for(i in 1:length(lat2)) { loc <- match(lat2[i],lat) loc2 <- match(lon2[i], lon) print(loc); print(loc2) #Need to test to make sure loc equals loc2 freq_ppt <- c(data[i,4],data[i,6],data[i,8],data[i,10],data[i,12],data[i,14],data[i,...
2008 Jun 26
3
using contour() with x,y,z data?
Hello list, I'm new to R and I have a problem :-) Below is what my data file that looks like. I tried to import and contour this data by doing this: cv_data <- read.table("cv_data.csv",sep=",",header=TRUE) attach(cv_data) contour(x,y,z) I get the error "Error in contour.default(x,y,z) : increasing 'x', and 'y' values expected" I