Dear R Helpers,
I did a search for deleting rows based on conditions but wasn't able to
find an example that addressed the error that I am getting. I am hoping
that this is a simple syntax phenomenon that somebody else knows off the
top of their head. My apologies for not providing a
On Apr 15, 2013, at 9:58 AM, Sparks, John James wrote:
Dear R Helpers,
I did a search for deleting rows based on conditions but wasn't able to
find an example that addressed the error that I am getting. I am hoping
that this is a simple syntax phenomenon that somebody else knows off the
.
- Original Message -
From: Sparks, John James jspa...@uic.edu
To: r-help@r-project.org
Cc:
Sent: Monday, April 15, 2013 12:58 PM
Subject: [R] Remove Rows Based on Factor
Dear R Helpers,
I did a search for deleting rows based on conditions but wasn't able to
find an example
03:00:00 17.3 17.5 16.2 15.9 443522 16.5
A.K.
- Original Message -
From: arun smartpink...@yahoo.com
To: Sparks, John James jspa...@uic.edu
Cc: R help r-help@r-project.org
Sent: Monday, April 15, 2013 1:32 PM
Subject: Re: [R] Remove Rows Based on Factor
Hi,
May be this helps:
ZZ
Hello
I have a dataset with 151 dependent variables and estimated in 6 different
conditions, and each condition is repeated 3 times. It si proteomic and
therefore expensive, so few repetitions.
I want to conduct a stepwise discriminant analysis to identify the variables
that really matter. To do
-Original Message-
How do I find and remove the two duplicate rows?
Try ?unique()
See also ?duplicated and consider the usage
d[ !duplicated(d), ]
where d is your data frame. But read the 'details' part of the help page
closely...
S Ellison
-Original Message-
I have a very long list of data-points (+2300) and i know
from my histogram that there are outliers which are affecting my mean.
If extreme values are known to be unreliable*, take a look at robust statisical
methods (or even the median) instead of the mean.
To further David's comment, just think what the world would be like if
Alexander
Fleming had discarded an obvious outlier in 1928 (
http://en.wikipedia.org/wiki/Penicillin#Discovery).
On Tue, Apr 9, 2013 at 7:46 AM, David Winsemius dwinsem...@comcast.netwrote:
On Apr 9, 2013, at 4:12 AM,
Hi Everyone,
I have a very long list of data-points (+2300) and i know from my histogram
that there are outliers which are affecting my mean.
I was wondering if anyone on here knows a way i can quickly get R to
calculate and remove data which is 3 standard deviations from the mean? I am
hoping
On 09-04-2013, at 13:12, Lorna lor...@essex.ac.uk wrote:
Hi Everyone,
I have a very long list of data-points (+2300) and i know from my histogram
that there are outliers which are affecting my mean.
I was wondering if anyone on here knows a way i can quickly get R to
calculate and
On Apr 9, 2013, at 4:12 AM, Lorna wrote:
Hi Everyone,
I have a very long list of data-points (+2300) and i know from my
histogram
that there are outliers which are affecting my mean.
I was wondering if anyone on here knows a way i can quickly get R to
calculate and remove data which is 3
Hi,
Try ?unique()
You haven't provided reproducible data or information about the package. So,
this may or may not work.
dat1- data.frame(idvar=c(rep(1,2),2,4),col2=c(7,7,8,9))
dat1
# idvar col2
#1 1 7
#2 1 7
#3 2 8
#4 4 9
unique(dat1)
# idvar col2
#1 1 7
Dear all,
Could anyone help me with the following?
DATA - data.frame(rbind(c(Red1, 1, 1, 1), c(Blue1, 1, 1, 1), c(Red2, 1,
1, 1), c(Red3, 1, 1, 1)))
colnames(DATA) - c(A, B,C, D)
#Option 1
DATA - DATA[-2, ] #Same result I would like to achieve with Option 2
#Option 2 - I would like to do it
r-help-boun...@r-project.org
Cc:
Sent: Sunday, April 7, 2013 2:31 PM
Subject: [R] Remove a row containing a specific value for a column
Dear all,
Could anyone help me with the following?
DATA - data.frame(rbind(c(Red1, 1, 1, 1), c(Blue1, 1, 1, 1), c(Red2, 1,
1, 1), c(Red3, 1, 1, 1)))
colnames
Dear All,
sorry, got stuck again on the following: let us say we have:
a -c(1:5)
b -c(6:10)
d -cbind(a,b)
from d I would like to remove total number of rows based on the length of f. So
if:
f -c(1)
my result is working great with the following solution:
d[-length(f),]
so I get:
Hi Andras,
what about:
d[-(1:length(f)), ]
a b
[1,] 3 8
[2,] 4 9
[3,] 5 10
Best,
Gergely
On 20 March 2013 22:53, Andras Farkas motyoc...@yahoo.com wrote:
Dear All,
sorry, got stuck again on the following: let us say we have:
a -c(1:5)
b -c(6:10)
d -cbind(a,b)
from d I would
Hi,
Try:
f-c(1,2)
d[-seq_along(f),]
# a b
#[1,] 3 8
#[2,] 4 9
#[3,] 5 10
A.K.
- Original Message -
From: Andras Farkas motyoc...@yahoo.com
To: r-help@r-project.org
Cc:
Sent: Wednesday, March 20, 2013 5:53 PM
Subject: [R] remove specific number of rows from a matrix
Dear All
: Thursday, February 21, 2013 1:45 PM
To: Johannes Brand
Cc: R help
Subject: Re: [R] remove rows in data frame by average
Hi,
May be this helps:
dat1- read.table(text=
Subject Block Trial Feature1 Feature2
1 1 1 48 40
1 1 2 62 18
1 2 134 43
1 2 2 51 34
1 3 1
Dear all,
I have a data frame, which looks like this:
Subject | Block | Trial | Feature1 | Feature2
1 | 1 | 1 | ... | ...
1 | 1 | 2 | ... | ...
1 | 2 | 1 | ... | ...
1 | 2 | 2 | ... | ...
1 | 3 | 1 | ... | ...
...| ...| ...| ... | ...
Can I remove the Trial column by averaging all the rows
-
From: Johannes Brand brandjohan...@gmx.de
To: r-help@r-project.org
Cc:
Sent: Thursday, February 21, 2013 12:02 PM
Subject: [R] remove rows in data frame by average
Dear all,
I have a data frame, which looks like this:
Subject | Block | Trial | Feature1 | Feature2
1 | 1 | 1
45.0
#6 2 3 38.0 28.0
A.K.
- Original Message -
From: Johannes Brand brandjohan...@gmx.de
To: r-help@r-project.org
Cc:
Sent: Thursday, February 21, 2013 12:02 PM
Subject: [R] remove rows in data frame by average
Dear all,
I have a data frame, which looks like
Message-
From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org] On
Behalf
Of arun
Sent: Thursday, February 21, 2013 1:45 PM
To: Johannes Brand
Cc: R help
Subject: Re: [R] remove rows in data frame by average
Hi,
May be this helps:
dat1- read.table(text=
Subject
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi
I am sure I am missing something really basic, but I can't figure it out.
I want to start R so that I can specify the location for the Library tree. In
principel simple:
As I only want it dependent on the directory I stat R in, I put a
On 13-02-15 9:28 AM, Rainer M Krug wrote:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
Hi
I am sure I am missing something really basic, but I can't figure it out.
I want to start R so that I can specify the location for the Library tree. In
principel simple:
As I only want it dependent on
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 15/02/13 15:41, Duncan Murdoch wrote:
On 13-02-15 9:28 AM, Rainer M Krug wrote: Hi
I am sure I am missing something really basic, but I can't figure it out.
I want to start R so that I can specify the location for the Library tree. In
On 13-02-15 9:54 AM, Rainer M Krug wrote:
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 15/02/13 15:41, Duncan Murdoch wrote:
On 13-02-15 9:28 AM, Rainer M Krug wrote: Hi
I am sure I am missing something really basic, but I can't figure it out.
I want to start R so that I can specify the
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1
On 15/02/13 16:06, Duncan Murdoch wrote:
On 13-02-15 9:54 AM, Rainer M Krug wrote: On 15/02/13 15:41, Duncan Murdoch
wrote:
On 13-02-15 9:28 AM, Rainer M Krug wrote: Hi
I am sure I am missing something really basic, but I can't figure it out.
please remove me from the R-help mailing list
thank you!
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
On Feb 12, 2013, at 10:12 , Sarah d'Apollonia wrote:
please remove me from the R-help mailing list
Instructions are found in the footer.
thank you!
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing list
Hi all,
I realised that my last email question and code was probably going to be a bit
of an eyesore for some people and that perhaps the best thing for me to do is
to pose the question of what it is I want to achieve, rather than what I've
written, if it helps people:
I'm writing a
1) We don't have your previous email and I doubt anyone here committed your
code to memory
2) No offense but this post is still an eye sore. Actually I am guessing
even worse than the first because there is no working example. The idea is
to provide *minimal* code that reproduces the problem -
Readers,
For a graph plot instruction:
plot(seq(10:50),type='h',yaxt='n',yaxs='i',lab=c(20,2,2),xlab='x axis
label',bty='l',main='graph title')
how to remove y-axis label and keep the x-axis label?
_
r2151
__
R-help@r-project.org mailing list
Hello,
Just use ylab = .
Hope this helps,
Rui Barradas
Em 30-01-2013 13:33, e-letter escreveu:
Readers,
For a graph plot instruction:
plot(seq(10:50),type='h',yaxt='n',yaxs='i',lab=c(20,2,2),xlab='x axis
label',bty='l',main='graph title')
how to remove y-axis label and keep the x-axis
Readers,
Am trying to plot a graph with type 'h' and want to remove the white
space between the plot lines and the x axis. The help section 'par'
suggests that the option 'mai' controls this feature, but the syntax
plot(...mai=c(0,1,1))
is ineffective
Any advice please?
--
r2151
Hi,
Please provide a reproducible example.
Regards,
Pascal
Le 29/01/2013 19:40, e-letter a écrit :
Readers,
Am trying to plot a graph with type 'h' and want to remove the white
space between the plot lines and the x axis. The help section 'par'
suggests that the option 'mai' controls this
On 29/01/2013, Pascal Oettli kri...@ymail.com wrote:
Hi,
Please provide a reproducible example.
test-seq(10:50)
plot(test,type='h',mai=c(0,1,1))
Tried
plot(test,type='h',yaxs='i')
but this has the non-wanted effect of removing white space from
between the highest peak and the upper (top)
Not sure wat you're trying to do... Can you explain more what you expect
your plot to look like?
What about plot(..., frame=FALSE)?
Ivan
--
Ivan CALANDRA
Université de Bourgogne
UMR CNRS/uB 6282 Biogéosciences
6 Boulevard Gabriel
21000 Dijon, FRANCE
+33(0)3.80.39.63.06
On 13-01-29 7:51 AM, e-letter wrote:
On 29/01/2013, Pascal Oettli kri...@ymail.com wrote:
Hi,
Please provide a reproducible example.
test-seq(10:50)
That's probably not doing what you think it does because you used a
colon instead of a comma.
plot(test,type='h',mai=c(0,1,1))
The
Something like
plot(test,type='h',yaxs='i', ylim = c(0, 60)) ?
You would need to figure out what the right values for ylim are.
John Kane
Kingston ON Canada
-Original Message-
From: inp...@gmail.com
Sent: Tue, 29 Jan 2013 14:51:32 +0200
To: kri...@ymail.com
Subject: Re: [R
Hello!
I wish, that my email-adress is removed from the R-help mailing list.
Thanks!
[[alternative HTML version deleted]]
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide
.
- Original Message -
From: M. Maurice m.mauric...@yahoo.de
To: R-help@r-project.org R-help@r-project.org
Cc:
Sent: Tuesday, January 22, 2013 7:13 AM
Subject: [R] Remove my adress from mailing list
Hello!
I wish, that my email-adress is removed from the R-help mailing list.
Thanks
: Re: [R] remove from column a group of elements I have in another
vector
You can probably do it with not in in R too:
for a data frame x where you want to remove rows where values in
column A are not in the vector y:
x[!(x$A %in% y), ]
If you'd provided a reproducible example, I could give
,
Estefania
From: Sarah Goslee sarah.gos...@gmail.com
To: Estefanía Gómez Galimberti tef...@yahoo.com
Cc: r-help@r-project.org r-help@r-project.org
Sent: Friday, December 21, 2012 4:56 PM
Subject: Re: [R] remove from column a group of elements I have in another
Hi,
I have a data frame and I would need to remove from one of
the columns a group of elements I have in another vector. How can I do that? I
know how to do it with criteria but i would need to do it in a more automatic
way
In SQL I would use where
not in
Thank you,
Estefania
You can probably do it with not in in R too:
for a data frame x where you want to remove rows where values in
column A are not in the vector y:
x[!(x$A %in% y), ]
If you'd provided a reproducible example, I could give code that works
in your particular circumstance.
Sarah
On Fri, Dec 21, 2012
Good morning!
I have the following data frame (df):
X.outer Y.outer X.PAD1 Y.PAD1 X.PAD2 Y.PAD2 X.PAD3 Y.PAD3 X.PAD4
Y.PAD4
73 574690.0 179740.0 574690.2 179740.0 574618.3 179650 574729.2 179674 574747.1
179598
74 574680.6 179737.0 574693.4 179740.0 574719.0 179688 574831.8
Hi Raphael,
see below.
I have the following data frame (df):
...
df2
X.PAD2 Y.PAD2
73 574618.3 179650
74 574719.0 179688
75 574719.0 179688
76 574723.5 179678
77 574724.9 179673
78 574747.1 179598
79 574641.8 179570
80 574639.6 179573
81 574618.3 179650
82 NA NA
83 NA
df2 - df2[!is.na(df2),] isn't doing what you want it to do because
df2 is a data.frame and not a vector
to solve your problem, review
http://stackoverflow.com/questions/4862178/r-remove-rows-with-nas-in-data-frame
On Thu, Dec 13, 2012 at 3:20 AM, raphael.fel...@art.admin.ch wrote:
Good
is.na(df2) is not doing what you think it is doing. Perhaps you should read
?na.omit.
---
Jeff NewmillerThe . . Go Live...
DCN:jdnew...@dcn.davis.ca.usBasics: ##.#.
You can use complete.cases:
df - df[complete.cases(df), ]
On Thu, Dec 13, 2012 at 3:20 AM, raphael.fel...@art.admin.ch wrote:
Good morning!
I have the following data frame (df):
X.outer Y.outer X.PAD1 Y.PAD1 X.PAD2 Y.PAD2 X.PAD3 Y.PAD3
X.PAD4 Y.PAD4
73 574690.0 179740.0
with the list elements differ in length.
A.K.
- Original Message -
From: raphael.fel...@art.admin.ch raphael.fel...@art.admin.ch
To: r-help@r-project.org
Cc:
Sent: Thursday, December 13, 2012 3:20 AM
Subject: [R] remove NA in df results in NA, NA.1 ... rows
Good morning!
I have
On 12/12/2012, Daniel Nordlund djnordl...@frontier.com wrote:
-Original Message-
From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org]
On Behalf Of e-letter
Sent: Tuesday, December 11, 2012 11:45 PM
To: r-help@r-project.org
Subject: [R] remove last row of a data
[mailto:r-help-boun...@r-project.org
]
On Behalf Of e-letter
Sent: Tuesday, December 11, 2012 11:45 PM
To: r-help@r-project.org
Subject: [R] remove last row of a data frame
Readers,
For a data set 'a':
1
2
3
4
Please what is the syntax to remove the last row and create a new
Readers,
For a data set 'a':
1
2
3
4
Please what is the syntax to remove the last row and create a new object 'b':
1
2
3
Thanks.
--
R2151
__
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting
-Original Message-
From: r-help-boun...@r-project.org [mailto:r-help-boun...@r-project.org]
On Behalf Of e-letter
Sent: Tuesday, December 11, 2012 11:45 PM
To: r-help@r-project.org
Subject: [R] remove last row of a data frame
Readers,
For a data set 'a':
1
2
3
4
Please
df - df[-which(is.na(df$Field)), ] - removing rows with NULL fields
df - df[-which(df$Field == ), ] - removing rows with empty fields
On Wednesday, November 28, 2012 2:23:00 PM UTC+5:30, catalin roibu wrote:
Dear R users,
I want to remove zero's or NA values after this model.
year
Dear R users,
I want to remove zero's or NA values after this model.
year value1 value2
1854 0 12
1855 0 13
1866 12 16
1877 11 24
year value1 value2
1 12 12
2 11 13
3 16
4 24
Thank you!
--
---
Catalin-Constantin ROIBU
Forestry engineer, PhD
Forestry Faculty of Suceava
Str. Universitatii no.
na.omit
--
View this message in context:
http://r.789695.n4.nabble.com/remove-NA-or-0-values-tp4651096p4651097.html
Sent from the R help mailing list archive at Nabble.com.
__
R-help@r-project.org mailing list
Hello,
You can't keep the tabular form and not have the same number of elements
in value2, what you can have is a list.
(I'm not seeing much sense in it, but if that's wht you want...)
dat - read.table(text =
year value1 value2
1854 0 12
1855 0 13
1866 12 16
1877 11 24
, header = TRUE)
idx
Hello,
You should keep this in the list, the odds of getting more and better
answers are bigger.
As for your dataset, it doesn't have the same structure as your previous
example. If you want a list with all zeros and NAs removed you can try
(assuming it's named 'dat')
lapply(dat,
Hi frespider,
I think the problem is first that you are referring to column names that you
haven't yet defined. To add the column names you can use the dimnames
argument of the matrix function.
Asse - matrix(0,nrow=5,ncol=length(namVar), dimnames = list(NULL, namVar))
JoAnn
--
View this
Hi,,
Can I get help with this. I need to remove a column form the matrix if that
specific column has his all entry zero, here the code I wrote but it is not
working can you help me please
namVar -
Hello,
Three things:
1. You don't need an explicit comparison to TRUE,
if(all(Asse[,SSdiff]==0)){
will do the same.
2. Your matrix Asse doesn't have colnames, try to see the output of
colnames(Asse)
You forgot to assign colnames(Asse) - namVar.
3. Even if it did, SSdiff is the 4th column,
Hi,
I edited the code sorry,
I forgot the line before
Can you have look again please?
Thanks
--
View this message in context:
http://r.789695.n4.nabble.com/Remove-Column-from-matrix-tp4650334p4650348.html
Sent from the R help mailing list archive at Nabble.com.
12:52 PM
Subject: [R] Remove Column from matrix
Hi,,
Can I get help with this. I need to remove a column form the matrix if that
specific column has his all entry zero, here the code I wrote but it is not
working can you help me please
namVar -
c(TrlgWSST,TrlgWSSE,TrlgWSSR,SSdiff,TrlgWMSE,TrlgWR2
A colleague wrote the following syntax for me:
D = read.csv(x.csv)
## Convert -999 to NA
for (k in 1:dim(D)[2]) {
I = which(D[,k]==-999)
if (length(I) 0) {
D[I,k] = NA
}
}
The dataset has many missing values. I am running several regressions on
this dataset, and want to
On Nov 9, 2012, at 10:50 AM, Eiko Fried tor...@gmail.com wrote:
A colleague wrote the following syntax for me:
D = read.csv(x.csv)
## Convert -999 to NA
for (k in 1:dim(D)[2]) {
I = which(D[,k]==-999)
if (length(I) 0) {
D[I,k] = NA
}
}
The dataset has many missing
Marc et. al:
On Fri, Nov 9, 2012 at 9:05 AM, Marc Schwartz marc_schwa...@me.com wrote:
On Nov 9, 2012, at 10:50 AM, Eiko Fried tor...@gmail.com wrote:
A colleague wrote the following syntax for me:
D = read.csv(x.csv)
## Convert -999 to NA
for (k in 1:dim(D)[2]) {
I =
On Nov 9, 2012, at 11:23 AM, Bert Gunter gunter.ber...@gene.com wrote:
Marc et. al:
On Fri, Nov 9, 2012 at 9:05 AM, Marc Schwartz marc_schwa...@me.com wrote:
On Nov 9, 2012, at 10:50 AM, Eiko Fried tor...@gmail.com wrote:
A colleague wrote the following syntax for me:
D =
Hi, I am trying to remove a series of records from a large dataframe. The
script I have written works fine but takes a long time to run. Can anyone
suggest a quicker way to do this?
Here is an example of the code I've written. The end result of this bit of
code would be a dataframe with any
Hello,
If I understand it well,
idx - !dat$id %in% bad$id
dat[idx, ]
Also, to create bad you are complicating, this would do:
bad - data.frame(id = c(1,4))
Hope this helps,
Rui Barradas
Em 22-10-2012 12:04, penguins escreveu:
Hi, I am trying to remove a series of records from a large
.
- Original Message -
From: penguins cat...@bas.ac.uk
To: r-help@r-project.org
Cc:
Sent: Monday, October 22, 2012 7:04 AM
Subject: [R] Remove records from a large dataframe
Hi, I am trying to remove a series of records from a large dataframe. The
script I have written works fine but takes
Thanks Rui, your solution works great and is so fast!
--
View this message in context:
http://r.789695.n4.nabble.com/Remove-records-from-a-large-dataframe-tp4646990p4647029.html
Sent from the R help mailing list archive at Nabble.com.
__
Hi,
i have an small doubt.
How can we remove serial-number column while writing a dataframe in to a csv
file ?
for eg:-
write.csv(MyDataFrame,c:/MyData.csv)
name place
--- ---
1 antonyuk
2 john usa
3 arjun ind
here, in
On Thu, Sep 13, 2012 at 8:47 AM, Rantony antony.akk...@ge.com wrote:
Hi,
i have an small doubt.
How can we remove serial-number column while writing a dataframe in to a csv
file ?
for eg:-
write.csv(MyDataFrame,c:/MyData.csv)
name place
--- ---
1
Thanks.
From: Pramod [via R] [mailto:ml-node+s789695n4642989...@n4.nabble.com]
Sent: Thursday, September 13, 2012 1:27 PM
To: Akkara, Antony (GE Energy, Non-GE)
Subject: Re: Remove serial number column in a Dataframe into CSV
Add another argument to
Hi Folks,
I'm trying to find a way to remove all terms in a formula that contain a
particular interaction.
For example, in the formula below, I'd like to remove all terms that
contain the b:c interaction.
attributes(terms( ~ a*b*c*d))$term.labels
[1] a b c d a:b
~ a*b*d + a*c*d
-- Bert
On Thu, Sep 13, 2012 at 10:49 AM, Alexander Shenkin ashen...@ufl.edu wrote:
Hi Folks,
I'm trying to find a way to remove all terms in a formula that contain a
particular interaction.
For example, in the formula below, I'd like to remove all terms that
contain the b:c
On Sep 13, 2012, at 11:00 AM, Bert Gunter wrote:
~ a*b*d + a*c*d
That seemed pretty clear and obvious, but I started wondering how to tell the
machine to do it. Here is another idea:
grep(b:c, attr(terms(~a*b*c*d), term.labels ) ,invert=TRUE, value=TRUE)
[1] a b c d a:b
: Thursday, September 13, 2012 11:28 AM
To: Bert Gunter
Cc: Alexander Shenkin; r-help@r-project.org
Subject: Re: [R] remove all terms with interaction factor in formula
On Sep 13, 2012, at 11:00 AM, Bert Gunter wrote:
~ a*b*d + a*c*d
That seemed pretty clear and obvious, but I started
-project.org] On
Behalf
Of David Winsemius
Sent: Thursday, September 13, 2012 11:28 AM
To: Bert Gunter
Cc: Alexander Shenkin; r-help@r-project.org
Subject: Re: [R] remove all terms with interaction factor in formula
On Sep 13, 2012, at 11:00 AM, Bert Gunter wrote:
~ a*b*d + a*c*d
-
From: David Winsemius [mailto:dwinsem...@comcast.net]
Sent: Thursday, September 13, 2012 4:15 PM
To: William Dunlap
Cc: Bert Gunter; Alexander Shenkin; r-help@r-project.org
Subject: Re: [R] remove all terms with interaction factor in formula
On Sep 13, 2012, at 11:53 AM, William Dunlap
*Hi all,*
I'm trying to filter a file through the columns. This file below is a
example of my data frame. My true data frame has seven hundred thousand
columns and 500 hundred lines. I need to identify and to remove all columns
that all elements equal a number 1. In this my case, columns were
On 25-08-2012, at 02:11, Kate Dresh wrote:
*Hi all,*
I'm trying to filter a file through the columns. This file below is a
example of my data frame. My true data frame has seven hundred thousand
columns and 500 hundred lines. I need to identify and to remove all columns
that all
dreshk...@gmail.com
To: r-help@r-project.org
Cc:
Sent: Friday, August 24, 2012 8:11 PM
Subject: [R] remove column
*Hi all,*
I'm trying to filter a file through the columns. This file below is a
example of my data frame. My true data frame has seven hundred thousand
columns and 500 hundred lines
-
From: r-help-boun...@r-project.org [mailto:r-help-bounces@r-
project.org] On Behalf Of Tonja Krueger
Sent: Wednesday, August 22, 2012 10:16 AM
To: r-help@r-project.org
Subject: [R] Remove similar rows from matrix
Hi everybody,
I have a matrix (mat) from which I want to remove
@r-project.org
Subject: [R] Remove similar rows from matrix
Hi everybody,
I have a matrix (mat) from which I want to remove all rows that
differ from
other rows in that matrix only by having one ore two NA’s instead of
a
numbers.
I would like to remove rows with more NA’s
Hi everybody,
I have a matrix (mat) from which I want to remove all rows that differ from
other rows in that matrix only by having one ore two NA’s instead of a
numbers.
I would like to remove rows with more NA’s preferably, so in the end the
matrix would look like mat2.
Hi!
Both yy[!(yy %in% xx)] and yy[is.na(match(yy,xx))] work a treat!
Developing this topic can anyone tell me how to extract rows which are not
replicated across 2 data frames. For example:
z1-c(1,2,3,4)
z2-c(5,6,7,8)
zz- data.frame(cbind(z1,z2))
x1-c(3,4)
x2-c(7,8)
xx-
many thanks for lots of different solutions. I have a couple of very large
data frames but using the unique identifier for each row and Arun's solution
zz[is.na(match(zz$z1,xx$x1)),]
has worked perfectly,
Thanks!
--
View this message in context:
Hi
-Original Message-
From: r-help-boun...@r-project.org [mailto:r-help-bounces@r-
project.org] On Behalf Of penguins
Sent: Monday, August 20, 2012 1:15 PM
To: r-help@r-project.org
Subject: Re: [R] Remove several numbers from a sequence
Hi!
Both yy[!(yy %in% xx)] and yy[is.na
Can anyone tell me how to remove several numbers for a sequence. For example:
xx- c(1,5,7,10)
yy-seq(1,10,1)
how do I get take xx away from yy to get the new sequence
2,3,4,6,8,9
Many thanks in advance
--
View this message in context:
Take a look at ?setdiff
Michael
On Aug 17, 2012, at 12:18 PM, penguins cat...@bas.ac.uk wrote:
Can anyone tell me how to remove several numbers for a sequence. For example:
xx- c(1,5,7,10)
yy-seq(1,10,1)
how do I get take xx away from yy to get the new sequence
2,3,4,6,8,9
Many
HI,
Try this:
yy[is.na(match(yy,xx))]
#[1] 2 3 4 6 8 9
A.K.
- Original Message -
From: penguins cat...@bas.ac.uk
To: r-help@r-project.org
Cc:
Sent: Friday, August 17, 2012 12:18 PM
Subject: [R] Remove several numbers from a sequence
Can anyone tell me how to remove several numbers
On 17-08-2012, at 18:18, penguins wrote:
Can anyone tell me how to remove several numbers for a sequence. For example:
xx- c(1,5,7,10)
yy-seq(1,10,1)
how do I get take xx away from yy to get the new sequence
2,3,4,6,8,9
You can also do this
yy[!(yy %in% xx)]
Berend
yy[!yy%in%xx]
Clint BowmanINTERNET: cl...@ecy.wa.gov
Air Quality Modeler INTERNET: cl...@math.utah.edu
Department of Ecology VOICE: (360) 407-6815
PO Box 47600FAX:(360) 407-7534
Olympia, WA 98504-7600
Hi everyone.
I'm trying to customize a biplot (RDA). I would like to remove all axes
ticks. Therefore, I was using *ann=FALSE* (see following example). However,
it only clear the axis 1 and 2 leaving ticks on axis 3 and 4. Any
suggestions to get rdi of the remaining ticks?
data(varespec)
Hi,
Here i have a Matrix
MyMatrix -
NameAge
- ---
ANTONY27
IMRAN 30
RAJ 22
NAHAS 32
GEO 42
and here i have an array with Minimum and Maximum values.
MinMaxArray - data.frame(MIN = 25,MAX=35)
MIN
Hello,
Please learn how to use dput(), it's not your first post.
And try the following.
myMatrix - data.matrix(read.table(text=
NameAge
ANTONY27
IMRAN 30
RAJ 22
NAHAS 32
GEO 42
, header=TRUE))
MinMaxArray -
: Tuesday, July 31, 2012 3:58 AM
Subject: [R] Remove a complete row as per the Range in a Matrix
Hi,
Here i have a Matrix
MyMatrix -
Name Age
- ---
ANTONY 27
IMRAN 30
RAJ 22
NAHAS 32
GEO 42
and here i
201 - 300 of 632 matches
Mail list logo