similar to: conditional filter resulting in 2 new dataframes

Displaying 20 results from an estimated 1100 matches similar to: "conditional filter resulting in 2 new dataframes"

2012 Dec 04
2
computing marginal values based on multiple columns?
Hello all, I have what feels like a simple problem, but I can't find an simple answer. Consider this data frame: > x <- data.frame(sample1=c(35,176,182,193,124), sample2=c(198,176,190,23,15), sample3=c(12,154,21,191,156), class=c('a','a','c','b','c')) > x sample1 sample2 sample3 class 1 35 198 12 a 2 176 176
2010 Nov 04
2
Converting Strings to Variable names
Hi all, I am processing 24 samples data and combine them in single table called CombinedSamples using following: CombinedSamples<-rbind(Sample1,Sample2,Sample3) Now variables Sample1, Sample2 and Sample3 have many different columns. To make it more flexible for other samples I'm replacing above code with a for loop: #Sample is a string vector containing all 24 sample names for (k in
2012 Jul 31
2
phantom NA/NaN/Inf in foreign function call (or something altogether different?)
Dear experts, Please forgive the puzzled title and the length of this message - I thought it would be best to be as complete as possible and to show the avenues I have explored. I'm trying to fit a linear model to data with a binary dependent variable (i.e. Target.ACC: accuracy of response) using lrm, and thought I would start from the most complex model (of which "sample1.lrm1" is
2010 Sep 07
1
average columns of data frame corresponding to replicates
Hi Group, I have a data frame below. Within this data frame there are samples (columns) that are measured more than once. Samples are indicated by "idx". So "id1" is present in columns 1, 3, and 5. Not every id is repeated. I would like to create a new data frame so that the repeated ids are averaged. For example, in the new data frame, columns 1, 3, and 5 of the original
2008 May 21
2
Problem in converting natural numbers to bits and others
Hi, I just started using R for about one week and I have few problems. i)I have a problem in finding right function to convert a table of natural numbers to bitwise. For a simple example; I have the below table:- Column Col1 Col2 Col3 Sample1 5 7 10 Sample2 0 2 1 Sample3 4 0 0 Supposedly i wanted to convert to :- Column Col1 Col2 Col3
2006 Jun 29
1
kmeans clustering
Hello R list members, I'm a bio informatics student from the Leiden university (netherlands). We were asked to make a program with different clustering methods. The problem we are experiencing is the following. we have a matrix with data like the following research1 research2 research3 enz sample1 0.5 0.2 0.4 sample2 0.4
2010 May 21
2
Data reconstruction following PCA using Eigen function
Hi all, As a molecular biologist by training, I'm fairly new to R (and statistics!), and was hoping for some advice. First of all, I'd like to apologise if my question is more methodological rather than relating to a specific R function. I've done my best to search both in the forum and elsewhere but can't seem to find an answer which works in practice. I am carrying out
2010 Jun 13
1
using latticeExtra plotting confidence intervals
I am wanting to plot a 95% confidence band using segplot, yet I am wanting to have groups. For example if I have males and females, and then I have them in different races, I want the racial groups in different panels. I have this minor code, completely made up but gets at what I am wanting, 4 random samples and 4 samples of confidence, I know how to get A & B into one panel and C&D in to
2011 Jan 20
1
Problems with ecodist
Dear Dr.Goslee and anyone may intrested in matrix manipulate, I am using your ecodist to do mantel and partial mantel test, I have locality data and shape variation data, and the two distance matrixs are given as belowings. When I run the analysis, it is always report that the matrix is not square, but I didn't know what's wrong with my data. Would you please help me on this. I am quite
2009 Sep 20
4
correlation help
Dear group, I have a matrix like the following: Name Sample1 sample2 sample3 sample4 ..... sample(n) nm1 10.5 13.5 30 31 nm2 8 11 34 29 nm3 9 10.3 27.8 35 nm(j) I want to be able to calculate correlation between all pairs of names. For example (nm1,nm2),
2010 Feb 25
1
taking the median across similar data
Dear All, I am analyzing the miRNA data set in which I have 817 unique probes for each they have 20 features each . I have to group the similar features and take the median across them so that I have a data with no repeats to perform invariant analysis . My data looks something similar format probename sample1 sample2 sample3 A 2.3 2.4 2.5 A
2008 Feb 07
1
How to split a factor (unique identifier) into several others?
Hello, I have a data frame with a factor column, which uniquely identifies the observations in the data frame and it looks like this: sample1_condition1_place1 sample2_condition1_place1 sample3_condition1_place1 . . . sample3_condition3_place3 I want to turn it into three separate factor columns "sample", "condition" and "place". This is what I did so far: #
2008 Mar 20
2
Error in function (classes, fdef, mtable): unable to find an inherited method for function "indexProbes", for signature "exprSet", "character"
Hello Everyone, I am writing programs in R from 7 months and I am able to solve most of the errors/issues except for this current post. My Task is to read a Microsoft Excel file(textE_to_affy.csv) which contains the Microarray Expression Values collected from the Illumina Microarray experiment. These collected intensity values need to be normalized(Rank Invariant Normalization) by using the R
2023 May 02
1
[External] Error in percentage stacked barplot
## you may need to install HH install.packagess("HH") library(HH) hellisheidi <- read.table(text=" Component Sample1 Sample2 Sample3 CaO 45 52 48 SiO2 25 22 18 Al2O3 15 11 14 TiO2 6 5
2012 Jul 13
4
Side by side strip charts
Hi, I'm looking for some ideas on how to reproduce the attached image in R. There are three samples, each of size n = 10. The first is drawn from a normal distribution with mean 60 and standard deviation 3. The second is drawn from a normal distribution with mean 65 and standard deviation 3. The third is drawn from a normal distribution with mean 70 and standard deviation 3.
2023 May 03
1
[External] Error in percentage stacked barplot
Dear Richard,? Thank you very much for your reply. I went through the code and it worked. I was also able to change the colours.? I was wondering if I can change the legend position; instead of being in the bottom to be on the left side.? I tried the following but without any success strip = FALSE strip.right = TRUE likert(t(hellisheidi), ReferenceZero=.5, xlab="X-lab",
2011 Sep 09
2
NMDS plot and Adonis (PerMANOVA) of community composition with presence absence and relative intensity
Hi! Thanks for providing great help in R-related statistics. Now, however I'm stuck. I'm not a statistics person but I was recommended to use R to perform a nmds plot and PerMANOVA of my dataset. Sample(treatment) in the columns and species (OTU) in the rows. I have 4 treatments (Ambient Temperature, Ambient temperature+Low pH, High temperature, High temperature+low pH), and I have 16
2007 Mar 15
2
how to...
I have to perform ANOVA's on many different data organized in a dataframe. I can run an ANOVA for each sample, but I've got hundreds of data and I would like to avoid manually carrying out each test. in addition, I would like to have the results organized in a simple way, for example in a table, wich could be easy to export. thank you for assistance simone
2006 Jul 10
2
pvclust missing values problem
Hello all, I posted a question to this list last week and received no response. I am unsure if this means no-one knows the answer or if I posed the question badly. I'm going to assume I posed the question badly and try again. I am new to R so it is quite likely it's a very naive question, however if there is something blindingly obvious that I am missing or if there is another resource I
2011 Sep 26
1
How to Store the executed values in a dataframe & rle function
Hi group, This is how my test file looks like: Chr start end sample1 sample2 chr2 9896633 9896683 0 0 chr2 9896639 9896690 0 0 chr2 14314039 14314098 0 -0.35 chr2 14404467 14404502 0 -0.35 chr2 14421718 14421777 -0.43 -0.35 chr2 16031710 16031769 -0.43 -0.35 chr2 16036178 16036237 -0.43 -0.35 chr2 16048665 16048724 -0.43 -0.35 chr2 37491676 37491735 0 0 chr2 37702947 37703009 0 0