similar to: data frame filtration

Displaying 20 results from an estimated 7000 matches similar to: "data frame filtration"

2002 Sep 10
3
print
Hi all, Suppose I have a vector Fruits <- c('Apple','Orange','Pear','Banana','Mango') I want to print the statement "The fruits in the basket are: Apple, Orange, Pear, Banana, Mango" If I do: print(paste('The fruits in the basket are:',Fruits)) The output is: [1] "The fruits in the basket are: Apple" "The fruits in
2006 Jul 06
3
Comparing two matrices [Broadcast]
It might be a bit faster to do matrix indexing: R> tbm <- as.matrix(tb) # turn it into a character matrix R> tmat[cbind(match(tbm[,2], rownames(tmat)), match(tbm[,1], colnames(tmat)))] <- 1 > tmat Apple Orange Mango Grape Star A 1 1 1 0 0 O 1 1 0 0 0 M 0 0 1 0 0 G 0 0 0 0 0 S 1 1 1 0
2006 Jul 06
3
Comparing two matrices
hi: I have matrix with dimensions(200 X 20,000). I have another file, a tab-delim file where first column variables are row names and second column variables are column names. For instance: > tmat Apple Orange Mango Grape Star A 0 0 0 0 0 O 0 0 0 0 0 M 0 0 0 0 0 G 0 0 0 0 0 S 0 0 0 0 0
2004 Oct 18
3
答复: R plot problems
Thank you for your help! I gave you an example, you could run it in R . Maybe you will understand my meaning clearly. x <- data.frame(main.name="AAA", x.name=rep(c("Apply","Watermelon","Lemon","Banana",
2006 Sep 01
1
Reading many files at once
dear group, i have 100 files starting with 'hsa-*'. ex. file: fruit p-value ------------ apple 0.0003 orange 0.004 kiwi 0.0003 peach 0.0004 I want to read all these files and create a single matrix. here each file may have different fruit names. in the matrix i want to have a union of all fruits and those should be the rows in the matrix and file names should be columns.
2010 May 19
1
Calling R-tists
Participants in the R User Conference, useR! 2010, July 21-23, (http://R-project.org/useR-2010) will each receive a t-shirt, thanks to the sponsorship of Mango Solutions (http://www.mango-solutions.com/). This email is a call for designs for the front of the t-shirt. The design should be made using a single color of your choice. The design should be in the form of a high-resolution (at least
2004 Oct 18
2
答复: 答复: R plot problems
Yes! You are right ! It is perpendicular to the axis. Thank you very much! Could I choose the angle ,such as 45 degree? Best Regards! Ivy Li YMS in Production & Testing Semiconductor Manufactory International(ShangHai) Corporation #18 ZhangJiang Road, PuDong New Area, Shanghai, China Tel: 021-5080-2000 *11754 Email: Ivy_Li at smics.com -----orig--- Hi Ivy, How about x <-
2008 Sep 08
3
extracting max row from data matrix
dear group, i have a data matrix with some replicate items with different values. I want to extract the row with max value. for example: > x fruit weight 1 apple 1.3 2 apple 1.5 3 apple 1.6 4 orange 1.4 5 orange 1.6 x is a data frame. I want to extract unique items from fruits that has max weight. that is: 3 apple 1.6 5 orange 1.6 I want to be able to use
2001 Mar 14
3
get statistics by group
Hi, I have a data set look like this: ================================= Fruit Quty apple 20 banana 10 orange 17 apple 30 apple 15 orange 26 banana 15 .........and so on .......... ================================= The level of fruit is 30, that is, there are 30 different fruits. I'd like to compute some simple statistics for each different fruit and get output like this:
2007 Feb 22
3
List filtration
Hello R-ologists, Imagine you have a list "list" like so: >list [[1]] [1] "IPI00776145.1" "IPI00776187.1" [[2]] [1] "Something" "IPI00807764.1" "IPI00807887.1" [[3]] [1] "IPI00807764.1" [[4]] [1] "Somethingelse" What I need to achieve is a filtered list "list2" like so: >list2 [[1]] [1]
2017 Aug 30
2
Dataframe Manipulation
i want to do a market basket analysis and I?m trying to create a dataset for that i have two tables, one table contains daily transaction of products in which each row of table shows item purchased by the customer, The second table contains parent group under those products are fallen, for example under fruit category there are several fruits like mango, banana, apple etc. i want to create a third
2011 Aug 11
1
help with loops
hi I need help with list object. I have a list object > a <- c('apple','orange','grape') > b <- c('car','truck','jeep') > c <- list(a,b) > names(c) <- c('fruit','vehicle') > c $fruit [1] "apple" "orange" "grape" $vehicle [1] "car" "truck"
2013 Oct 24
2
R: Optional argument to be used in a subset function
I'm writing a function that needs an optional variable. If the variable is given, then a subset must be made using that variable, but if the variable is not given the subset must be done using all the values for that variable (ignoring that variable). Something like this: *band <- function(file, fruit = "apple", optional=TRUE) {* *data <- read.csv(file)* *a <-
2003 Jul 30
1
S & R Public Training Courses in the UK
(Apologies for cross posting) Mango Solutions are pleased to announce the following public courses in the UK. Date Course Location 29th - 31st October Advanced <http://www.mango-solutions.com/pubadvanceds.htm> S-PLUS Programming Oxford 11th - 13th November R <http://www.mango-solutions.com/pubrprogramming.htm> Programming London 14th November R for
2007 May 13
1
Dropdown boxes in tcltk and R
Hello, I'm very much a newbie in R and more so in tcltk so apologies if this question is stupid. Basically I am trying to use the combobox example found here: http://bioinf.wehi.edu.au/~wettenhall/RTclTkExamples/DropDown.html . What I want to do is in that example get fruitChoice as a variable in R in general. When I run that code, however, and the ask for fruitChoice it says
2017 Aug 30
1
Dataframe Manipulation
by using these two tables we have to create third table in this format where categories will be on the top and transaction will be in the rows, On 30 August 2017 at 16:42, Hemant Sain <hemantsain55 at gmail.com> wrote: > Hello Ulrik, > Can you please once check this code again on the following data set > because it doesn't giving same output to me due to absence of quantity,a
2004 Oct 29
5
pattern search
hi, I like to find a pattern within a giver sequence. There might be multiple occurences of the pattern. I like to know the number of occurences and the positions if possible. "grep" can tell me if a pattern exists but can't give me the information I need. Does anyone know any function that I can use or know how to do what I intend?. Thanks a lot. Sean
2017 Aug 31
0
Dataframe Manipulation
Hi Hemant, the solution is really quite similar, and the logic is identical: library(readr) library(dplyr) library(stringr) library(tidyr) data_help <- read_csv("data_help.csv") cat_help <- read_csv("cat_help.csv") # Helper function to split the Items and create a data_frame split_items <- function(items){ x <- items$Items_purchased_on_Receipts %>%
2017 Sep 04
1
Dataframe Manipulation
Hello Ulrik, Can you please explain this code means how and what this code is doing because I'm not able to understand it, if you can explain it i can use it in future by doing some Lil bit manipulation. Thanks data_help <- data_help %>% mutate(Purchase_ID = 1:n()) %>% group_by(Purchase_ID) %>% do(split_items(.)) cat_help %>% gather("Foo",
2008 Oct 02
1
R Training Courses
There are still places available on the following courses. For more detailed information and a registration form please contact training@mango-solutions.com, or visit our website at www.mango-solutions.com <http://www.mango-solutions.com/> . R for Finance **************************************************** Dates: 21st to 23rd October 2008. Duration: 3 days. Location: London.