similar to: Looping through a series of (csv) files

Displaying 13 results from an estimated 13 matches similar to: "Looping through a series of (csv) files"

2010 Oct 13
4
Change global env variables from within a function
Hi, I've looked all over for a solution to this, but haven't had much look in specifying what I want to do with appropriate search terms. Thus I'm turning to R-help. In the process of trying to write a simple function to rename individual column names in a data frame, I ran into the following problem: When I rename the columns within my function, I can't seem to get it to
2011 Jan 14
4
test
Hi, i have that table Thesis Day A B C 1 0 83.43 90.15 22.97 1 0 85.50 94.97 16.62 1 0 83.36 95.38 20.70 1 0 84.47 92.16 23.58 1 0 83.98 95.33 19.39 1 0 82.86 93.78 24.55 1 0 83.39 92.67 19.56 1 0 85.17 95.24 17.95 1 0 81.62 93.32 28.49 1 0 82.99 92.85 19.73 1 0 81.11 95.67 27.20 1 0 83.39 94.69 16.51 1 0 79.56 89.87 30.39 1 0 80.54 93.32 21.76 1 0 82.11 92.58 22.17 1 14 85.65 94.00 19.19 1 14
2013 Mar 13
2
Extract letters from a column
Dear list: I would like to extract three letters from first and second elements in one column and make a new column. For example below, > tempdf = read.table("clipboard", header=T, sep='\t') > tempdf name var1 var2 abb 1 Tom Cruiser 1 6 TomCru 2 Bread Pett 2 5 BrePet 3 Arnold Schwiezer 3 7 ArnSch > (p1 =
2011 Jun 28
1
lattice multiple y-scale possible?
Hi I am attempting to use the lattice bwplot function to generate boxplots of numerous parameters (1-panel/parameter) by site (x-axis). The parameters have quite different ranges of values, so it would be best to have a separate y-axis range for each panel. Below is a basic example of what I am trying to do. As is seen, the y-axes need to be scaled individually to make this useful. Any
2011 May 19
1
Creating a "shifted" month (one that starts not on the first of each month but on another date)
Hello! I have a data frame with dates. I need to create a new "month" that starts on the 20th of each month - because I'll need to aggregate my data later by that "shifted" month. I wrote the code below and it works. However, I was wondering if there is some ready-made function in some package - that makes it easier/more elegant? Thanks a lot! # Example data:
2007 May 12
1
function similar to "get" that works for both an object, and elements of an object?
#Is there a single function similar to "get" that works for both an object, and elements of an object ? #(I want the function to be able to return objects, and/or the deeper elements of an object.) #(i.e. elements of a dataframe and/or list)? #e.g. tempdf = data.frame(a=c(4,5,6) , b=c(10,11,12) ) templist= list(x=tempdf, y=c(1,2)) get('tempdf') #works as desired
2012 Aug 03
2
Recursive function calls
My apologies, I know that this is not a new problem, but I'm not sure how to find the answer I want to recursively loop over an object and trim trailing white space. When I use this function on a list of data.frame I get output like this: [1] "c(\" many spaces \", \" many spaces \")" "c(\" many spaces \", \" many spaces
2016 Jan 14
2
JDataFrame API
Hi Folks, If you need to send data from Java to R you may consider using the JDataFrame API -- which is used to convert data into JSON which then can be converted into a data frame in R. Here's the project page: https://coherentlogic.com/middleware-development/jdataframe/ and here's a partial example which demonstrates what the API looks like: String result = new JDataFrameBuilder()
2009 Dec 08
1
Printing 'k' levels of factors 'n' times each, but 'n' is unequal for all levels ?
Dear List, I need to print out each of 'k' levels of a factor 'n' times each, where 'n' is the number of elements belonging to each factor. I know that this can normally be done using the gl() command, but in my case, each level 'k' has an unequal number of elements. Example with code is as below: vc<-read.table("P:\\Transit\\CORRECT
2016 Jan 15
2
JDataFrame API
Hi Simon, Thanks for your feedback. -- this is an observation that I wasn't considering when I wrote this mainly because I am, in fact, working with rather small data sets. BTW: There is code there, it's under the bitbucket link -- here's the direct link if you'd still like to look at it: https://bitbucket.org/CoherentLogic/jdataframe Re "for practical purposes is
2016 Jan 15
0
JDataFrame API
Tom, this may be good for embedding small data sets, but for practical purposes is doesn't seem like the most efficient solution. Since you didn't provide any code, I built a test case using the build-in Java JSON API to build a medium-sized dataset (1e6 rows) and read it in just to get a ballpark (see https://gist.github.com/s-u/4efb284e3c15c6a2db16 # generate: time java -cp
2010 Oct 15
0
nomianl response model
Is there a way to estimate a nominal response model? To be more specific let's say I want to calibrate: \pi_{v}(\theta_j)=\frac{e^{\xi_{v}+\lambda_{v}\theta_j}}{\sum_{h=1}^m e^{\xi_{h}+\lambda_{h}\theta_j}} Where $\theta_j$ is a the dependent variable and I need to estimate $\xi_{h}$ and $\lambda_{h}$ for $h \in {1...,m}$. Thank you, Mauricio Romero Quantil S.A.S. Cel: 3112231150
2016 Jan 15
0
JDataFrame API
> On Jan 15, 2016, at 12:35 PM, Thomas Fuller <thomas.fuller at coherentlogic.com> wrote: > > Hi Simon, > > Thanks for your feedback. -- this is an observation that I wasn't > considering when I wrote this mainly because I am, in fact, working > with rather small data sets. BTW: There is code there, it's under the > bitbucket link -- here's the direct