r - Running out of memory with merge -
I have a panel data that looks like this:
(For my query only enough Deduction)
Persno 122 122 122 333 333 333 333 333 444 444 Income 1500 1500 2000 2000 2100 2500 2500 1500 2000 2200 Year 1990 1991 1992 1990 1991 1992 1993 1994 1992 1993 < / Pre> Now I want to give each row (parsono) years of work experience in the beginning of the year. I ddply hilf3 To create a product that looks like this:
Task experience: 1 2 3 1 2 3 4 5 1 2 > Now I have the ddply in my original panel data To merge the results: data & lt ;-( Merge (Data, Hilf 3, By. X = "Persno",) By.y = "Persno") < / Code> The panel data set is too large. The code is closed due to memory size error.
ERRUMSAGE:
1: In the make .inick (as Cheture (rows)):
Allocation of 4000Mb in total: Support (memory.Scz) See
What should I do?
Reading your question again, I think that you actually merge Just do not want to use just sort your original data frame and RBI from Bilghar to hilf3. Even more, your ddply -call probably can result in a 1: 0 sequence, which is not the most likely that you want data [order ( Data $ Persno, data $ year),] hilf3 = ddply (data. (Persno), summarized, bgwork = (year - minute (year) + data = 1) stopopnot ( Enroe (data) == Enro (HILF3) StopPNOT (All data ($ $ Persno == hilf3 $ Persno) $ $ Bgwork = hilf3 $ Bgwork
Comments
Post a Comment