similar to: transforming column of a dataframe by var- and median-functions

Displaying 20 results from an estimated 10000 matches similar to: "transforming column of a dataframe by var- and median-functions"

2008 Feb 05
1
R-Commander - pie charts menu blinded out
Hello, I hope somebody can help me. I'm using the R-comander with library(Rmcdr). Using the menu, I added an new data-matrix . After I wanted to draw a pie chart, but the problem is, that the pie chart menu is blinded out. In the concerning variable column, there are no NA -Value (is.na) . Anybody has a solution? thxs Iksmax
2008 Apr 27
1
parallel max, min, and median of dataframe columns
Hello, all, I have a dataframe of three rows and umpteen columns. I want to show the maximum, minimum, and median with a vertical line and a central dot (I'd use a boxplot, but with only three data points, that's overkill; I can't just use points, because of overlap and some of the other data plotted on the graph). This works: > boxplot(data_frame,
2007 Oct 22
3
median value dataframe coming from multiple dataframes
Hi all, I am not a skillful R programmer and has I am handling with large dataframes (about 30000 x 300) I am in need of an efficient function. I have 4 dataframes with the same dimension. I need to generate other dataframe with the some dimension than the others where in each position it has the median value of the 4 values in the same position coming from the 4 dataframes. Grateful by your
2012 Oct 15
2
median between matrix column
Dear useRs, 1. how to calculate single median value for two columns of a matrix? 2. i have a matrix of 16 columns and 365 rows, how to calculate median between columns 1 and 16, 2 and 16, 3 and 16, 4 and 16, 5 and 16 till 15th column. is there a loop command to do the said operation? regards eliza [[alternative HTML version deleted]]
2002 Mar 30
2
Inconsistency among mean, median, max, var
I found a strange inconsistency: If m is a matrix and d is a data frame then - mean(m), median(m), max(m) and max(d) all return a single value but - mean(d) returns the column means - median(d) fails - both var(m) and var(d) return the variance covariance matrix You pretty much have to experiment to figure this out since much of this behavior is not readily obvious from the help files.
2012 Jan 12
1
how to select column wich median is in this interval [5;6]
Hello, I have got a data frame df like this : > df e1 e2 e3 e4 1 1 11 1 21 2 2 12 2 22 3 3 13 3 23 4 4 14 4 24 5 5 15 5 25 6 6 16 6 26 7 7 17 7 27 8 8 18 8 28 9 9 19 9 29 10 10 20 10 30 where e1 ... e3 are vectors I have to select columns which median is in the interval [5;6] ( Here, for instance, e1 and e3) I would not want to use loop... (for, while) I search
2010 Jan 02
2
Boxplot- input the median point and the median value
Dear, I am a newbie to R. Now I am learning to draw boxplot using graphics(). I want to highlight the median position with a round point and the value left (or on the top of)to the point. Please kindly share the command and thank you. Elaine [[alternative HTML version deleted]]
2006 Feb 17
1
Transforming results of the summary function
Hi all, I have a question about transforming the data from summary function. Let's say I have a data frame like this: > x = data.frame(a = c(rep("lev1", 5), rep("lev2", 5)), b = c(rnorm(5)+2, rnorm(5))) > x a b 1 lev1 1.5964765 2 lev1 2.2945609 3 lev1 3.5285787 4 lev1 1.4439838 5 lev1 2.2948826 6 lev2 1.7063506 7 lev2 -0.4042742 8 lev2
2004 Jun 24
3
The "median" function in R does not work properly.
Hi, 1.) The "median" function does not work well. Please refer to the data below (same data is attached as txt-delimited). This is what I try to do in R: median ( dataf [2:9] ) I get warning: "needs numeric data" 2.) BUT if apply the median to a single vector: median ( dataf [,2]] ) then it works: 3.) How come the "median"
2007 May 08
3
Median
Hello. I need calculate the median of several column of a data.frame, in a new column of this data frame, but the median operator only calculate from a vector. I have made a functionc that calculate the median but it is very slow. Are there any method in any package to calculate this? Best regards. Jose Sierra. A B C -0.01678042
2013 Mar 21
2
Displaying median value over the horizontal(median)line in the boxplot
Hi, set.seed(45) test1<-data.frame(columnA=rnorm(7,45),columnB=rnorm(7,10)) #used an example probably similar to your actual data apply(test1,2,function(x) sprintf("%.1f",median(x))) #columnA columnB # "44.5"? "10.2" par(mfrow=c(1,2)) lapply(test1,function(x) {b<-
2009 Jul 20
2
calculating median with a condition
Hello, I am trying to calculate the median of numbers across each row for the data shown below , with the condition that if the number is negative, that it should be ignored and the median should be taken of only the positive numbers. For eg: data is in Column A,B,C. Column D and E demonstrates what I want to get as answer A B C Median median value -13.6688115 -32.50914055
2010 May 27
1
median test
Hi all, I have found the following function online median.test<-function(y1,y2){ z<-c(y1,y2) g <- rep(1:2, c(length(y1),length(y2))) m<-median(z) fisher.test(z<m,g)$p.value } in http://www.mail-archive.com/r-help@r-project.org/msg95278.html I have the following data > group1 <- c(2, 2, 2, 1, 4, 3, 1, 1) > group2 <- c(3, 1, 3, 1, 4, 1, 1, 1, 7, 1, 1, 1, 1,
2003 Sep 27
2
CI on median
Dear friends, I'm probably wrong but is there anything better than bootstrap to get a confidence interval of the median from a population with unspecified distribution ? Best wishes Troels Ring, Aalborg, Denmark
2009 Aug 21
4
help with median for each row
Hi, I tried looking through google search on whether there's a way to computer the median for each row of a nxn matrix and return the medians for each row for further computation. And also if the number of columns in the matrix are even, how could I specify which median to use? Thank you very much! -- Edward Chen [[alternative HTML version deleted]]
2006 Jun 30
5
median of gamma distribution
Doese anyone know a R function to find the median of a gamma distribution? [[alternative HTML version deleted]]
2010 Apr 08
1
Question about simple.median.test
I am studying "Using R for Introductory Statistics" and find it in general very useful. At present, I am stumbling over the function simple.median.test. > x [1] 12.8 3.5 2.9 9.4 8.7 0.7 0.2 2.8 1.9 2.8 3.1 15.8 > simple.median.test (x,median=5) [1] 0.3876953 > simple.median.test (x,median=10) [1] 0.03857422 until here it is identical to the document. Then I
2009 Apr 14
2
any other fast method for median calculation
Hi there, I got a data frame with more than 200k columns. How could I get median of each column fast? mapply is the fastest function I know for that, it's not yet satisfied though. It seems function "median" in R calculates median by "sort" and "mean". I am wondering if there is another function with better algorithm. Any hint? Thanks, Xin Zheng
2012 Feb 04
2
How to Compare the median to the mean?
Okay, so I have a homework projecr for R, and we had to input the following link as some sort of data: nb10 <- read.table("http://www.adjoint-functors.net/su/web/314/R/NB10"). Afterwards, we have to use fivenum(nb10) to find max, min, quantiles, and sd, but I'm okay with this. The next question is where I'm stuck. The question is as follows; Compare the median (use the
2006 Mar 22
3
ordering boxplots according to median
Dear R-users, Does anyone knows how I can order my serie of boxplots from lowest to highest median (which is much better for visualization purposes). thanks in advance, willem [[alternative HTML version deleted]]