Re: [R] color palettes

2014-08-10 Thread carol white
I don't make a chart with 1000 colors. I allocate 1000 colors for 1000 iterms and then, the selected items based on a criterion will get a color out of 1000. Thanks On Friday, August 8, 2014 4:38 PM, David L Carlson dcarl...@tamu.edu wrote: I would suggest not using pie charts and not

[R] Best way to merge 300+ .5MB dataframes?

2014-08-10 Thread Grant Rettke
Good afternoon, Today I was working on a practice problem. It was simple, and perhaps even realistic. It looked like this: • Get a list of all the data files in a directory • Load each file into a dataframe • Merge them into a single data frame Because all of the columns were the same, the

Re: [R] Best way to merge 300+ .5MB dataframes?

2014-08-10 Thread Jeff Newmiller
Just load the data frames into a list and give that list to rbind. It is way more efficient to be able to identify how big the final data frame is going to have to be at the beginning and preallocate the result memory than to incrementally allocate larger and larger data frames along the way

Re: [R] simulation data with dichotomous varuables

2014-08-10 Thread William Revelle
Dear Thanoon, You might look at the various item simulation functions in the psych package. In particular, for your problem: R1 - sim.irt(10,1000,a=3,low = -2, high=2) R2 - sim.irt(10,1000,a=3,low = -2, high=2) R12 - data.frame(R1$items,R2$items) #this gives you 20 items, grouped with high

Re: [R] Is there a package for EFA with multiple groups?

2014-08-10 Thread William Revelle
Dear Josh and Elizabeth, Josh suggested one way of doing it with the psych package. As of today, the psych package (version psych_1.4.8) , I have included a new function (faBy) that will work with the statsBy function to do EFA for each of multiple groups. Basically, it just calls the statsBy

Re: [R] Best way to merge 300+ .5MB dataframes?

2014-08-10 Thread David Winsemius
On Aug 10, 2014, at 11:51 AM, Grant Rettke wrote: Good afternoon, Today I was working on a practice problem. It was simple, and perhaps even realistic. It looked like this: • Get a list of all the data files in a directory • Load each file into a dataframe • Merge them into a single

Re: [R] Best way to merge 300+ .5MB dataframes?

2014-08-10 Thread Jeff Newmiller
Err... sorry... you have to use do.call with base rbind as David illustrates. I am spoiled by rbind.fill from the plyr package. rbind.fill accepts the list directly and also fills in any missing columns with NA, which avoids having to dig through all the files to find any oddballs.

Re: [R] Best way to merge 300+ .5MB dataframes?

2014-08-10 Thread John McKown
On Sun, Aug 10, 2014 at 1:51 PM, Grant Rettke g...@wisdomandwonder.com wrote: Good afternoon, Today I was working on a practice problem. It was simple, and perhaps even realistic. It looked like this: • Get a list of all the data files in a directory OK, I assume this results in a vector

[R] Just stumbled across this: Advanced R programming text code - from Hadley

2014-08-10 Thread John McKown
Well, it says that it's from Hadley Wickham. https://github.com/hadley/adv-r quote This is code and text behind the Advanced R programming book. The site is built using jekyll, with a custom plugin to render .rmd files with knitr and pandoc. To create the site, you need: jekyll and s3_websiter

[R] Problem with assignment 1 part 1

2014-08-10 Thread michelle maurin
I think my code is very close I can seem to be able to debug it Might be something very simple I know the problem is on the last 3 lines of code can you please help? Thanks Michelle __ R-help@r-project.org

Re: [R] Problem with assignment 1 part 1

2014-08-10 Thread Hasan Diwan
We can try, but we're not going to be able to do much without the code being pasted in the email. -- H On 10 August 2014 19:08, michelle maurin michimau...@hotmail.com wrote: I think my code is very close I can seem to be able to debug it Might be something very simple I know the problem is

Re: [R] Problem with assignment 1 part 1

2014-08-10 Thread John McKown
What code. Also, the forum has a no homework policy. Your subject implies this is homework, so you might not get any answers. You might get a hint or two though. On Aug 10, 2014 10:00 PM, michelle maurin michimau...@hotmail.com wrote: I think my code is very close I can seem to be able to debug