Displaying 20 results from an estimated 300 matches similar to: "Need help on data frame"
2002 Jan 18
2
length of dimnames???
Hi:
I have made a lot of progress reading and manipulating large data
files, thanks to the help of several of you. I am now stuck with
writing the final file with the following error (see also the full
transcript below):
Error in as.matrix.data.frame(x) : length of dimnames[2] not
equal to array extent
I do not know what it means and could not find how to get around that
in the manual nor
2011 Apr 05
2
Help to check data before putting it in a database
The example scene:
I have a database with stats about each goal made by my soccer team. This
database (a data frame in R) is organized in lines (goals) with a set of
columns containing data about these goals (player name, tactic position,
etc). For now, this database will be called "data.frame1".
What I need is to feed this "data.frame1" with new information about my team
2007 Aug 14
2
Question about unicode characters in tcltk
hello list,
Can someone help me figure out why the following code doesn't work?
I'm trying to but both Greek letters and subscripts into a tcltk menu.
The code creates all the mu's, and the 1 and 2 subscripts, but it
won't create the 0. Is there a certain set of characters that R won't
recognize the unicode for? Or am I input the \u2080 incorrectly?
library(tcltk)
m
2003 Jun 06
2
little manipulation on data frame
Dear all,
I have data like 3 coulmns and many rows. Each entry
is less than 10.
Example
x y z
1 5 3 2
2 3 7 8
3 8 9 5
4 5 4 6
--------------------------
---------------------------
I have to sum entries of each coulmn (seperately) till
it be 10. This i have to start for each row. And I
want to assign no. of rows needed including that row
too(it to be 10 or 10+, the moment it exceeds 10, i
2005 Aug 12
2
coercing created variables into a new data frame using na.omit()
Hi,
I am an R newbie and one thing I am having trouble with binding variables that
I have created within one data frame into a new data frame when using
na.omit(). To illustrate this problem I will give the example I am working on
and the approah I have been using:-
data.frame1<-filepath....
attach(data.frame1)
#create a new variable using a function
new.variable<-rep(1,length(weight3))
2012 Mar 01
1
mb_m buffer not cleared if parseEval fails
Hi,
I am using RInside for one of the applications that I'm using. The error
that occured is as follows.
When I use R.parseEval("xyz") if the parse fails then the mb_m is not
cleared and hence all subsequent
calls to R.parseEval fail.
example:
when R.parseEval("stringConcatfactoryrandom") is executed the R instance
looks like this
(gdb) p R
$7 = (RInside &)
2008 May 26
1
To draw observation [m, n] from 20 data frames named frame1, ... , frame20
Hi all,
I have 20 data frames, named frame1, ... , frame20. Each data frame has the
dimension 20x5. I need to build a function that calls out the observation in
Row 1, Col 2 from all 20 data frames and places it in a vector of length 20. I
have tried the following code:
vect <- rep(0,20)
for(i in 1:20){
vect[i] <- paste("frame",i,"[1,2]",sep="")
}
The
2008 Sep 17
5
inserting values for null
I have a dataframe D.F1
>dim (D.F1)
14351 9
This dataframe has values and for some 1000 rows it holds NULL values.I hace
found the missing values for about 500 and have those in another dataframe
D.F.sub.2
>dim(D.F.sub.2)
500 9
as dataframe is a subset of D.F1 the coulmn 1 in D.F.sub.2 is a subset of
D.F1.I have to insert the values in D.F1 in other fields while the coulmn 1
in both
2012 Jul 13
3
Column create and Update using function
Hi,
here i have a Max and Min values
Min <-3
Max <-6
and also a matrix like this,
ABC XYZ PQR
------ ------- -------
2 4 3
5 4 8
7 1 3
In this i need to check each particular column values are between Max and
Min value.
If the coulmn value not coming between Max and
2010 Jan 20
1
Merge and join data
Hi,
I'm looking to combine two data frames. Several of the columns are in
common while the others need to be summed up. The apply functions and
the merge functions don't seem to be working. I've included a basic
example of what I'm trying to do below. Thanks!
Sean
data.frame1<-as.data.frame(matrix(c('winter','dredge','515',100,150),1,5))
2011 Nov 10
1
grid.pack and grid.frame bewilder me
Hello R friends,
I get quite confused in using the grid graphic function grid.pack( )
and grid.frame ( ). Here is a simple example:
library(grid)
grid.frame(name="frame1")
grid.pack("frame1",rectGrob(width=unit(0.5,"npc"),
height=unit(0.5,"npc"), gp=gpar(col="red")))
what I expect is a rectangle with half the default device's
1999 Mar 01
1
"xpdrows.data.frame" (PR#131)
This is a follow-up to bug sent to days ago, which bounced from r-devel
because
the example was to large. Now example is smaller, and behaviour is as
belo,
EXEPT that r-windows not any more bombs, so main problem is
"xpdrows.data.frame"???
By the way, how to debug this example under windows? debug() doesnt
accept
the functions used (.Primitive), and R wont run under gdb --- may have
2012 Jan 14
3
add column with values found in another data frame
I am positive this problem has a very simple solution, but I have been
unable to find it, so I am asking for your help. I need to know how to look
something up in one data frame and add it as a column in another. If I have
a data frame that looks like this:
> frame1
ID score test age
1 Guy1 10 1 20
2 Guy1 13 2 20
3 Guy2 9 1 33
4 Guy2 11 2 33
and another frame that looks like this:
2013 Jan 03
3
Make a column from columns
Hi,
I have a data matrix with 13 columns and 55 rows. First coulmn is year and
other are monthly values for 55 years.
Now i want to create a single column of all the values ( i e a single time
series column from column 2 to 13 ).
Is it the for loop that works here ...how ?
or how i can rearrange the data so that it becomes a times series column.
hope i made the question clear .
thank you,
2013 Feb 13
3
match in dependence of 2 columns
Hello,
i want to match a column of one data.frame to another, my problem is, that i
only want to match the data, if 2 columns are equal.
i have a example:
data.frame1
cu.nr. name value
A 1 Evo 100
B 1 Mer 80
C 2 Ford
2008 Nov 05
3
Sort help
Geneset_name #Chromosome #Hit_in_Biomart
original_geneset_len Missing.genes
[1,] "AGUIRRE_PANCREAS_CHR12" "1" "51"
"59" "8"
[3,] "AGUIRRE_PANCREAS_CHR9" "1" "24"
"24"
2014 Sep 18
1
difference between install from source and install from repositories
Hi,
What is the difference between the R installation from source and the R
installation from ubuntu repositories. Specifically when I install
R-3.1.1 on ubuntu 14.04 from sources ldflags and CXXFLAGS are different
that those from the installation from a repo.
Installation from sources:
R CMD config --ldflags
-Wl,--export-dynamic -fopenmp -L/home/prana/prana_R/third-party/install/lib/R/lib
2006 Oct 16
3
lda
I'm trying to do a linear discriminant analysis on a dataset of three
classes ("Affinities"), using the MASS library:
> data.frame2 <- na.omit(data.frame1)
>
> data.ld = lda(AFFINITY ~ ., data.frame2, prior = c(1,1,1)/3)
Error in var(x - group.means[g, ]) : missing observations in cov/cor
What does this error message mean and how can I get rid of it?
Thanks!
Pieter
2010 Oct 29
2
doubt in climate variability analysis in R!
Hello all,
I am trying to use "clim.pact" package for my work, but since this is the beginning for me to use gridded datasets in "R", I am having some trouble.
I want to do seasonal analyses like trends, anomalies, variograms, EOF and probably kriging too to downscale my 1 degree gridded data to 0.5. So, as a first step, I compiled my entire dataset (with 25
2002 Jun 27
1
Simple Matrix plot question
Hello.
I'd like to produce a simple pairs-like plot
with two data frames - but not a traditional scatter-plot matrix -
just multiple bivariate plots of data.frame1[i] vs data.frame2[i] ...
In other words, given data frames X and Y, I'd like multiple plots on a
page like:
Y1 Y2 Y3
X1
X2
X3
Thanks in advance.
-R