similar to: Search a string inside a data.frame

Displaying 20 results from an estimated 90000 matches similar to: "Search a string inside a data.frame"

2011 Jan 06
1
Find and remove elemnts of a data frame
Dear all, I have a data frame that is created like that data.frame(x=CRX[-1],y=CRY[-1],z=CRagent[[1]]$sr) the output looks like 45 116 162 -30.89105988567164 46 128  79 -42.66296679571184 47 180 195 -30.45626175641315 48 114  83 -45.26843476475688 49 118  73 -46.85389245327003 How can I select only the rows that their third column is higher that -45? This will return the following 116 162
2012 Feb 21
3
Plot Many Data to same plot
Dear all, I have a function that for a variable number of inputs plots them to the same plot I am doing this quite simply by plot(seq(from=start, to=stop, length.out=np), datalist[[1]]$dataset                                                                  xlim=c(start, stop), ylim=c(0, 1), type="l")                                                                                      
2011 Apr 27
6
Assignments inside lapply
Dear all I would like to ask you if an assignment can be done inside a lapply statement. For example I would like to covert a double nested for loop for (i in c(1:dimx)){ for (j in c(1:dimy)){ Powermap[i,j] <- Pr(c(i,j),c(PRX,PRY),f) } } to something like that: ij<-expand.grid(i=seq(1:dimx),j=(1:dimy)) unlist(lapply(1:nrow(ij),function(rowId) { return
2011 Dec 02
3
find and replace string
Dear all, I would like to search in a string for the second occurrence of a symbol and replace the symbol after it For example my strings look like sta_+1+0_field2ndtry_0000$01.cfg I want to find the digit that comes after the second +, in that case is zero and then over a loop create the strings below sta_+1+0_field2ndtry_0000$01.cfg sta_+1+1_field2ndtry_0000$01.cfg
2010 Sep 08
2
Matrixes inside matrixes
Hello everyone, Could you please help me find out if R supports matrixes inside matrixes? This is what I would like to do I have an area map of humidity per km. I would like at every cell to keep also information about the height of this area, the current temperature etc. Is something like that supported? I would like to thank you in advance for your help Best Regards Alex
2011 Feb 02
2
Help me apply mapply
Hello all I would like to ask your help use mapply. I have a function called findCell that takes two arguments(x,sr) where x is a vector of size two (e.g x<-c(2,3) and sr is a matrix. I would like to call many times the findCell function (thus I need mapply) for different x inputs but always for the same sr. as x is a vector of size two (two cells) I want to pass inside inside the following
2010 Sep 09
2
See what is inside a matrix
Hello everyone.. Is there any graphical tool to help me see what is inside a matrix? I have 100x100 dimensions matrix and as you already know as it does not fit on my screen R splits it into pieces. I would like to thank you in advance for your help Best Regards Alex [[alternative HTML version deleted]]
2012 Mar 07
3
GPS handling libraries or (String manipulation)
Dear all, I would like to ask you if R has a library that can work with different GPS formats For example  I have a string of this format N50° 47.513 E006° 03.985 and I would like to convert to GPS decimal format. that means for example converting the part N50° 47.513 to 50 + 47/60 + 513/3600. Is it possible to do that with R? What is the name of such a library? I would like to thank you in
2010 Oct 18
1
Looking for covariance function -OR- how do you search
Hello everyone., I am looking for a covariance function this not the first time I have this type of problem (to find which function does something). I try in google with "R cran covariance function" but usually this ends with different results that do not help me that much. Could you please try to advice me how to search for what function implements the functionality you want.
2013 Mar 27
1
Averaging Out many rows from a column AND funtion to string
Dear all, 1) I have a very large matrix of  str(keep)  num [1:153899, 1:3415] -98.6 -95.8 -96.4 -95.8 -98 ... that  I would like to reduce its size to something like str(keep)  num [1:1000, 1:3415] -98.6 -95.8 -96.4 -95.8 -98 ...  or anything similar in size as this is a matrix that needs plotting (so is ok if it is 1000 row, 995, or 1123) I think what I need here is a way of selecting
2010 Aug 10
1
partial match of one column in data frame to another character vector
Here is some data (dput output below) > myData id group 1 D599 A 2 002-0004 B 3 F01932 A 18 F16 B 19
2010 Nov 17
2
How to catch warnings
Hello when my code executes I receive the message that were some warnings. I want to catch warning messages at run time so to print some local variables and try to understand why this warning happens. I searched on internet and I tried withCallingHandlers( which seems to work but as I used Rkward the result is awful. I get a prompt to copy paste a value only while at the same time my background
2012 Mar 10
2
Window on a vector
Dear all, I have a large vector (lets call it myVector) and I want to plot its value with the logic below yaxis<-myVector[1] yaxis<-c(xaxis,mean(myvector[2:3]) yaxis<-c(xaxis,mean(myvector[4:8]) yaxis<c(xaxis,mean(myvector[9:16]) yaxis<c(xaxis,mean(myvector[17:32]) this has to stop when the new ..... yaxis<c(xaxis,mean(myvector[1024:2048]) will not find the correspondent number
2010 Nov 22
1
plot inside function does not work
Hello everyone, when I commit a plot using console(command line?) plot works fine. I have created a function that plots based on the input. This function is called plot_shad. When I call this function alone in the command line I get my plot. Then I tried to use another function as depicted_below to do some calculation before calling the function that does the plotting.
2010 Nov 18
1
Why some times R-halts?
Hello everyone. I have written a small function that returns a 3*n array where n is typicall between 5-55. I issued in R shweights<-shadowing_weights(x,xr) and I got the result in less that one sec. then I tried to see what is inside the shweights array and thus I issued the edit(shweights) which 10 mins right now is busy and got no reply yet back. As I am using rkward I tried from gui the
2012 Feb 05
2
vectors of matrix as iinput to lapply
Dear all I am using lapply (actually mclapply that share the same syntax). I want to call the same function that takes as input a vector. My initial data structure is a matrix that I want to cut it to multiple vectors (one vector for every row of the matrix) and then feed that to the function by using mclapply. Could you please help me converting the matrices to nrow times vectors. I would
2010 Nov 18
3
Sample covariance matrix in R
Hello everyone. I would like to find the sample covariance matrix using R. So far I read on the wikipedia what a sample_covariance is http://en.wikipedia.org/wiki/Sample_covariance according to wikipedia one vector is enough to calculate the sample covariance matrix. In R I tried cov(myvector) and I get the reply that I need to pass either two argument or one matrix with x,y values . How can I
2010 Oct 26
5
Zoom in in a plot
in a simple plot. When i do plot is it possible to zoom in or out or this is not possible at all? Best Regards Alex [[alternative HTML version deleted]]
2011 May 28
2
reduce printing accuracy
Dear all, I would like to print a few values with less digits than the default. How I can reduce how many digits are printed ?(warning: not the real integer resolution but what is shown in screen) Best Regards Alex
2012 Mar 26
2
many curves to the same plot
Dear all, I would like to plot under the same plot many curves like mycdf<-ecdf(runif(100)) plot(mycdf) curve(mycdf,from=-1,to=1) mycdf<-ecdf(runif(200)+3) plot(mycdf) curve(mycdf,from=-1,to=1) as you can see each new call to curve redraws (erases) the window. How I can have an effect like plot(mycdf) lines(mycdf2) lines(mycdf3) I would like to thank you in advance for your help