Céline Lüscher
2017-Sep-12 11:57 UTC
[R] comparition of occurrence of multiple variables between two dataframes
Yes of course, I can share this short view of the datas. Here is the head() of data100, containing all the trees with a final value higher than 100?: CV11 CV12 CV13 CV14 CV15 CV21 CV22 CV23 CV24 CV25 CV26 CV31 CV32 CV33 CV41 CV42 CV43 CV44 CV51 CV52 IN11 IN12 IN13 1291 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1083 0 4 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 3919 0 0 0 0 0 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 0 0 0 14685 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 4021 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 5452 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 IN14 IN21 IN22 IN23 IN31 IN32 IN33 IN34 BA11 BA12 BA21 DE11 DE12 DE13 DE14 DE15 GR11 GR12 GR13 GR21 GR22 GR31 GR32 1291 0 0 0 0 0 0 0 0 30 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1083 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 3919 0 0 1 0 2 0 0 0 2 0 0 0 3 0 0 0 0 0 0 11 0 0 0 14685 0 0 0 0 0 0 0 0 11 0 0 0 0 0 0 0 0 0 0 0 0 0 0 4021 0 0 0 0 0 0 0 0 11 0 0 0 0 0 0 0 0 0 0 0 0 0 0 5452 0 0 1 0 0 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 0 0 0 EP11 EP12 EP13 EP14 EP21 EP31 EP32 EP33 EP34 EP35 NE11 NE12 NE21 OT11 OT12 OT21 OT22 ecoval 1291 0 8 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1192 1083 0 8 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 424 3919 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 380 14685 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 370 4021 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 358 5452 0 0 0 0 0 0 1 0 0 11 0 0 0 0 1 0 0 356 The columns are the possible structures found on a tree (cavity, scar?) And the same for the data0?: CV11 CV12 CV13 CV14 CV15 CV21 CV22 CV23 CV24 CV25 CV26 CV31 CV32 CV33 CV41 CV42 CV43 CV44 CV51 CV52 IN11 IN12 IN13 4728 0 0 0 1 0 0 0 3 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 5339 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 11766 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 796 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 3561 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 10581 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 IN14 IN21 IN22 IN23 IN31 IN32 IN33 IN34 BA11 BA12 BA21 DE11 DE12 DE13 DE14 DE15 GR11 GR12 GR13 GR21 GR22 GR31 GR32 4728 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 5339 1 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 11766 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 0 0 796 1 1 0 0 1 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 3561 0 0 0 0 0 0 0 0 3 0 0 0 0 0 0 0 0 0 0 0 0 0 0 10581 0 0 0 1 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 EP11 EP12 EP13 EP14 EP21 EP31 EP32 EP33 EP34 EP35 NE11 NE12 NE21 OT11 OT12 OT21 OT22 ecoval 4728 0 0 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 99 5339 0 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 99 11766 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 99 796 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 98 3561 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 98 10581 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 1 0 98 In short, the question is about to find a test to compare the occurrence of the structures between the group higher than 100 and the group under 100. Thank you for your help, C. Gesendet von Mail f?r Windows 10 Von: Suzen, Mehmet Gesendet: mardi, 12 septembre 2017 13:24 An: C?line L?scher Cc: r-help at r-project.org Betreff: Re: [R] comparition of occurrence of multiple variables between two dataframes Do you have a simplified example with a code? It is not clear to me what do you mean by tree but if you refer to tree data structure, maybe you could change the data structure to tree (https://cran.r-project.org/web/packages/data.tree/vignettes/data.tree.html) and try to write comparison of two tree objects. It might be easier that data.frame alone. On 12 September 2017 at 12:27, C?line L?scher <c-luescher at hispeed.ch> wrote:> Hi everyone, I need your help to solve a problem with occurrence and two dataframes. > I have an excel table of 15200 lines. Each line correspond to a tree analyzed for its structures. I have all the structures in columns (48 structures). The occurrence of these structures has been counted on every tree. For example, the tree 12607 has 3 structures CV11, 1 structure IN12 and none (0) of the rest of all the other structures. The very last column is the value given to the tree, according to the structures found on it (each structure giving a number of point to the tree by its presence on it). > The question is: Are there some structures, or combination of structures, which give a high value to the tree ? Of course, according to the value of each structure, we can see which one has a higher value than the others (ex: structure CV11 has a value of 15, structure IN12 has a value of 4). But what I want to know is, if we take all the trees having a final value higher than 100 (we create a new dataframe "data100"), and we compare with the trees having a final value under 100 (we create another dataframe "data0"), can we find a significant difference in the number and occurrence of structures found on these trees? And which structure is related to trees with a higher value than 100 ? > For now, I have only a visual answer to the question. I did two boxplot of the data100 and data0, and I have seen some diff?rences : 2 structures are only found in the data100, which can be caracteristic of a final value higher than 100. The problem is that I?m looking for a test to prove this. > If you have any idea or proposition for solving this problem.. it will be great! > Best wishes, > C. > > > Gesendet von Mail f?r Windows 10 > > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code.[[alternative HTML version deleted]]
Suzen, Mehmet
2017-Sep-12 12:10 UTC
[R] comparition of occurrence of multiple variables between two dataframes
Hi C?line, Looks like you are looking for a statistical test between two sets of distributions, such as KS test, for example, generate histogram for each row in an identical way and run KS test. But if you are after simple difference you may use compare package ( https://cran.r-project.org/web/packages/compare/index.html). Best, -m PS: Data is already plural :) datas does not exist. On 12 September 2017 at 13:57, C?line L?scher <c-luescher at hispeed.ch> wrote:> Yes of course, I can share this short view of the datas. > > > > Here is the head() of data100, containing all the trees with a final value > higher than 100 : > > CV11 > > CV12 > > CV13 > > CV14 > > CV15 > > CV21 > > CV22 > > CV23 > > CV24 > > CV25 > > CV26 > > CV31 > > CV32 > > CV33 > > CV41 > > CV42 > > CV43 > > CV44 > > CV51 > > CV52 > > IN11 > > IN12 > > IN13 > > 1291 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1083 > > 0 > > 4 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 3919 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 2 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 14685 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 4021 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 5452 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > IN14 > > IN21 > > IN22 > > IN23 > > IN31 > > IN32 > > IN33 > > IN34 > > BA11 > > BA12 > > BA21 > > DE11 > > DE12 > > DE13 > > DE14 > > DE15 > > GR11 > > GR12 > > GR13 > > GR21 > > GR22 > > GR31 > > GR32 > > 1291 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 30 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1083 > > 3 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 3919 > > 0 > > 0 > > 1 > > 0 > > 2 > > 0 > > 0 > > 0 > > 2 > > 0 > > 0 > > 0 > > 3 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 11 > > 0 > > 0 > > 0 > > 14685 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 11 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 4021 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 11 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 5452 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 2 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > EP11 > > EP12 > > EP13 > > EP14 > > EP21 > > EP31 > > EP32 > > EP33 > > EP34 > > EP35 > > NE11 > > NE12 > > NE21 > > OT11 > > OT12 > > OT21 > > OT22 > > ecoval > > 1291 > > 0 > > 8 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1192 > > 1083 > > 0 > > 8 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 424 > > 3919 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 380 > > 14685 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 370 > > 4021 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 358 > > 5452 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 11 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 356 > > > > The columns are the possible structures found on a tree (cavity, scar?) > > > > And the same for the data0 : > > CV11 > > CV12 > > CV13 > > CV14 > > CV15 > > CV21 > > CV22 > > CV23 > > CV24 > > CV25 > > CV26 > > CV31 > > CV32 > > CV33 > > CV41 > > CV42 > > CV43 > > CV44 > > CV51 > > CV52 > > IN11 > > IN12 > > IN13 > > 4728 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 3 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 1 > > 0 > > 0 > > 5339 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 11766 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 796 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 3561 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 10581 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > IN14 > > IN21 > > IN22 > > IN23 > > IN31 > > IN32 > > IN33 > > IN34 > > BA11 > > BA12 > > BA21 > > DE11 > > DE12 > > DE13 > > DE14 > > DE15 > > GR11 > > GR12 > > GR13 > > GR21 > > GR22 > > GR31 > > GR32 > > 4728 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 5339 > > 1 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 11766 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 796 > > 1 > > 1 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 3561 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 3 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 10581 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > EP11 > > EP12 > > EP13 > > EP14 > > EP21 > > EP31 > > EP32 > > EP33 > > EP34 > > EP35 > > NE11 > > NE12 > > NE21 > > OT11 > > OT12 > > OT21 > > OT22 > > ecoval > > 4728 > > 0 > > 0 > > 1 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 99 > > 5339 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 99 > > 11766 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 99 > > 796 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 98 > > 3561 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 98 > > 10581 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 98 > > > > > > In short, the question is about to find a test to compare the occurrence > of the structures between the group higher than 100 and the group under 100. > > > > Thank you for your help, > > C. > > > > > > > > Gesendet von Mail <https://go.microsoft.com/fwlink/?LinkId=550986> f?r > Windows 10 > > > > *Von: *Suzen, Mehmet <msuzen at gmail.com> > *Gesendet: *mardi, 12 septembre 2017 13:24 > *An: *C?line L?scher <c-luescher at hispeed.ch> > *Cc: *r-help at r-project.org > *Betreff: *Re: [R] comparition of occurrence of multiple variables > between two dataframes > > > > Do you have a simplified example with a code? It is not clear to me > > what do you mean by tree but if you refer to tree data structure, > > maybe you could change the data structure to tree > > (https://cran.r-project.org/web/packages/data.tree/ > vignettes/data.tree.html) > > and try to write comparison of two tree objects. It might be easier > > that data.frame alone. > > > > On 12 September 2017 at 12:27, C?line L?scher <c-luescher at hispeed.ch> > wrote: > > > Hi everyone, I need your help to solve a problem with occurrence and two > dataframes. > > > I have an excel table of 15200 lines. Each line correspond to a tree > analyzed for its structures. I have all the structures in columns (48 > structures). The occurrence of these structures has been counted on every > tree. For example, the tree 12607 has 3 structures CV11, 1 structure IN12 > and none (0) of the rest of all the other structures. The very last column > is the value given to the tree, according to the structures found on it > (each structure giving a number of point to the tree by its presence on it). > > > The question is: Are there some structures, or combination of > structures, which give a high value to the tree ? Of course, according to > the value of each structure, we can see which one has a higher value than > the others (ex: structure CV11 has a value of 15, structure IN12 has a > value of 4). But what I want to know is, if we take all the trees having a > final value higher than 100 (we create a new dataframe "data100"), and we > compare with the trees having a final value under 100 (we create another > dataframe "data0"), can we find a significant difference in the number and > occurrence of structures found on these trees? And which structure is > related to trees with a higher value than 100 ? > > > For now, I have only a visual answer to the question. I did two boxplot > of the data100 and data0, and I have seen some diff?rences : 2 structures > are only found in the data100, which can be caracteristic of a final value > higher than 100. The problem is that I?m looking for a test to prove this. > > > If you have any idea or proposition for solving this problem.. it will > be great! > > > Best wishes, > > > C. > > > > > > > > > Gesendet von Mail f?r Windows 10 > > > > > > > > > [[alternative HTML version deleted]] > > > > > > ______________________________________________ > > > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > > > https://stat.ethz.ch/mailman/listinfo/r-help > > > PLEASE do read the posting guide http://www.R-project.org/ > posting-guide.html > > > and provide commented, minimal, self-contained, reproducible code. > > >[[alternative HTML version deleted]]
David L Carlson
2017-Sep-12 14:32 UTC
[R] comparition of occurrence of multiple variables between two dataframes
You need to learn how to send plain text messages. See below what happened to your html table when the list converted it to plain text. It is unreadable. In your original post, you say "The very last column is the value given to the tree, according to the structures found on it (each structure giving a number of point to the tree by its presence on it)." That suggests that the point value is based on the structures. If that is so the answer to your question is "yes", higher point values will have different numbers/combinations of structures because you computed point value from the structures. No statistical test between the two groups will be valid because the groups were not formed independently of the structures. Looking for associations between different types of structures would be a different question that would not be based on point value at all but would use some measure of association/correlation. ---------------------------------------- David L Carlson Department of Anthropology Texas A&M University College Station, TX 77843-4352 -----Original Message----- From: R-help [mailto:r-help-bounces at r-project.org] On Behalf Of Suzen, Mehmet Sent: Tuesday, September 12, 2017 7:11 AM To: C?line L?scher <c-luescher at hispeed.ch> Cc: r-help at r-project.org Subject: Re: [R] comparition of occurrence of multiple variables between two dataframes Hi C?line, Looks like you are looking for a statistical test between two sets of distributions, such as KS test, for example, generate histogram for each row in an identical way and run KS test. But if you are after simple difference you may use compare package ( https://cran.r-project.org/web/packages/compare/index.html). Best, -m PS: Data is already plural :) datas does not exist. On 12 September 2017 at 13:57, C?line L?scher <c-luescher at hispeed.ch> wrote:> Yes of course, I can share this short view of the datas. > > > > Here is the head() of data100, containing all the trees with a final > value higher than 100 : > > CV11 > > CV12 > > CV13 > > CV14 > > CV15 > > CV21 > > CV22 > > CV23 > > CV24 > > CV25 > > CV26 > > CV31 > > CV32 > > CV33 > > CV41 > > CV42 > > CV43 > > CV44 > > CV51 > > CV52 > > IN11 > > IN12 > > IN13 > > 1291 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1083 > > 0 > > 4 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 3919 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 2 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 14685 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 4021 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 5452 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > IN14 > > IN21 > > IN22 > > IN23 > > IN31 > > IN32 > > IN33 > > IN34 > > BA11 > > BA12 > > BA21 > > DE11 > > DE12 > > DE13 > > DE14 > > DE15 > > GR11 > > GR12 > > GR13 > > GR21 > > GR22 > > GR31 > > GR32 > > 1291 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 30 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1083 > > 3 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 3919 > > 0 > > 0 > > 1 > > 0 > > 2 > > 0 > > 0 > > 0 > > 2 > > 0 > > 0 > > 0 > > 3 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 11 > > 0 > > 0 > > 0 > > 14685 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 11 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 4021 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 11 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 5452 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 2 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > EP11 > > EP12 > > EP13 > > EP14 > > EP21 > > EP31 > > EP32 > > EP33 > > EP34 > > EP35 > > NE11 > > NE12 > > NE21 > > OT11 > > OT12 > > OT21 > > OT22 > > ecoval > > 1291 > > 0 > > 8 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1192 > > 1083 > > 0 > > 8 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 424 > > 3919 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 380 > > 14685 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 370 > > 4021 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 358 > > 5452 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 11 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 356 > > > > The columns are the possible structures found on a tree (cavity, > scar?) > > > > And the same for the data0 : > > CV11 > > CV12 > > CV13 > > CV14 > > CV15 > > CV21 > > CV22 > > CV23 > > CV24 > > CV25 > > CV26 > > CV31 > > CV32 > > CV33 > > CV41 > > CV42 > > CV43 > > CV44 > > CV51 > > CV52 > > IN11 > > IN12 > > IN13 > > 4728 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 3 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 1 > > 0 > > 0 > > 5339 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 11766 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 796 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 3561 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 10581 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > IN14 > > IN21 > > IN22 > > IN23 > > IN31 > > IN32 > > IN33 > > IN34 > > BA11 > > BA12 > > BA21 > > DE11 > > DE12 > > DE13 > > DE14 > > DE15 > > GR11 > > GR12 > > GR13 > > GR21 > > GR22 > > GR31 > > GR32 > > 4728 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 5339 > > 1 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 11766 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 796 > > 1 > > 1 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 3561 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 3 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 10581 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > EP11 > > EP12 > > EP13 > > EP14 > > EP21 > > EP31 > > EP32 > > EP33 > > EP34 > > EP35 > > NE11 > > NE12 > > NE21 > > OT11 > > OT12 > > OT21 > > OT22 > > ecoval > > 4728 > > 0 > > 0 > > 1 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 99 > > 5339 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 99 > > 11766 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 99 > > 796 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 98 > > 3561 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 98 > > 10581 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 0 > > 1 > > 0 > > 98 > > > > > > In short, the question is about to find a test to compare the > occurrence of the structures between the group higher than 100 and the group under 100. > > > > Thank you for your help, > > C. > > > > > > > > Gesendet von Mail <https://go.microsoft.com/fwlink/?LinkId=550986> f?r > Windows 10 > > > > *Von: *Suzen, Mehmet <msuzen at gmail.com> > *Gesendet: *mardi, 12 septembre 2017 13:24 > *An: *C?line L?scher <c-luescher at hispeed.ch> > *Cc: *r-help at r-project.org > *Betreff: *Re: [R] comparition of occurrence of multiple variables > between two dataframes > > > > Do you have a simplified example with a code? It is not clear to me > > what do you mean by tree but if you refer to tree data structure, > > maybe you could change the data structure to tree > > (https://cran.r-project.org/web/packages/data.tree/ > vignettes/data.tree.html) > > and try to write comparison of two tree objects. It might be easier > > that data.frame alone. > > > > On 12 September 2017 at 12:27, C?line L?scher <c-luescher at hispeed.ch> > wrote: > > > Hi everyone, I need your help to solve a problem with occurrence and > > two > dataframes. > > > I have an excel table of 15200 lines. Each line correspond to a tree > analyzed for its structures. I have all the structures in columns (48 > structures). The occurrence of these structures has been counted on > every tree. For example, the tree 12607 has 3 structures CV11, 1 > structure IN12 and none (0) of the rest of all the other structures. > The very last column is the value given to the tree, according to the > structures found on it (each structure giving a number of point to the tree by its presence on it). > > > The question is: Are there some structures, or combination of > structures, which give a high value to the tree ? Of course, according > to the value of each structure, we can see which one has a higher > value than the others (ex: structure CV11 has a value of 15, structure > IN12 has a value of 4). But what I want to know is, if we take all the > trees having a final value higher than 100 (we create a new dataframe > "data100"), and we compare with the trees having a final value under > 100 (we create another dataframe "data0"), can we find a significant > difference in the number and occurrence of structures found on these > trees? And which structure is related to trees with a higher value than 100 ? > > > For now, I have only a visual answer to the question. I did two > > boxplot > of the data100 and data0, and I have seen some diff?rences : 2 > structures are only found in the data100, which can be caracteristic > of a final value higher than 100. The problem is that I?m looking for a test to prove this. > > > If you have any idea or proposition for solving this problem.. it > > will > be great! > > > Best wishes, > > > C. > > > > > > > > > Gesendet von Mail f?r Windows 10 > > > > > > > > > [[alternative HTML version deleted]] > > > > > > ______________________________________________ > > > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > > > https://stat.ethz.ch/mailman/listinfo/r-help > > > PLEASE do read the posting guide http://www.R-project.org/ > posting-guide.html > > > and provide commented, minimal, self-contained, reproducible code. > > >[[alternative HTML version deleted]] ______________________________________________ R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
PIKAL Petr
2017-Sep-13 07:16 UTC
[R] comparition of occurrence of multiple variables between two dataframes
Hi Instead of posting head(data100) try to copy output of dput(head(data100)) directly to your post. This can show us your exact data together with their modes. And switch to plain text emails, HTML formating results in quite messy mails. Cheers Petr> -----Original Message----- > From: R-help [mailto:r-help-bounces at r-project.org] On Behalf Of C?line > L?scher > Sent: Tuesday, September 12, 2017 1:58 PM > To: Suzen, Mehmet <msuzen at gmail.com> > Cc: r-help at r-project.org > Subject: Re: [R] comparition of occurrence of multiple variables between two > dataframes > > Yes of course, I can share this short view of the datas. > > Here is the head() of data100, containing all the trees with a final value higher > than 100 : > > CV11 > CV12 > CV13 > CV14 > CV15 > CV21 > CV22 > CV23 > CV24 > CV25 > CV26 > CV31 > CV32 > CV33 > CV41 > CV42 > CV43 > CV44 > CV51 > CV52 > IN11 > IN12 > IN13 > 1291 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1083 > 0 > 4 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 3919 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 2 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 14685 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 4021 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 5452 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > > IN14 > IN21 > IN22 > IN23 > IN31 > IN32 > IN33 > IN34 > BA11 > BA12 > BA21 > DE11 > DE12 > DE13 > DE14 > DE15 > GR11 > GR12 > GR13 > GR21 > GR22 > GR31 > GR32 > 1291 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 30 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1083 > 3 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 3919 > 0 > 0 > 1 > 0 > 2 > 0 > 0 > 0 > 2 > 0 > 0 > 0 > 3 > 0 > 0 > 0 > 0 > 0 > 0 > 11 > 0 > 0 > 0 > 14685 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 11 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 4021 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 11 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 5452 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 2 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > > EP11 > EP12 > EP13 > EP14 > EP21 > EP31 > EP32 > EP33 > EP34 > EP35 > NE11 > NE12 > NE21 > OT11 > OT12 > OT21 > OT22 > ecoval > > > > > > 1291 > 0 > 8 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1192 > > > > > > 1083 > 0 > 8 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 424 > > > > > > 3919 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 380 > > > > > > 14685 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 370 > > > > > > 4021 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 358 > > > > > > 5452 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 11 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 356 > > > > > The columns are the possible structures found on a tree (cavity, scar?) > > And the same for the data0 : > > CV11 > CV12 > CV13 > CV14 > CV15 > CV21 > CV22 > CV23 > CV24 > CV25 > CV26 > CV31 > CV32 > CV33 > CV41 > CV42 > CV43 > CV44 > CV51 > CV52 > IN11 > IN12 > IN13 > 4728 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 3 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 1 > 0 > 0 > 5339 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 11766 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 796 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 3561 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 10581 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > > IN14 > IN21 > IN22 > IN23 > IN31 > IN32 > IN33 > IN34 > BA11 > BA12 > BA21 > DE11 > DE12 > DE13 > DE14 > DE15 > GR11 > GR12 > GR13 > GR21 > GR22 > GR31 > GR32 > 4728 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 5339 > 1 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 11766 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 796 > 1 > 1 > 0 > 0 > 1 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 3561 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 3 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 10581 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > > EP11 > EP12 > EP13 > EP14 > EP21 > EP31 > EP32 > EP33 > EP34 > EP35 > NE11 > NE12 > NE21 > OT11 > OT12 > OT21 > OT22 > ecoval > > > > > > 4728 > 0 > 0 > 1 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 99 > > > > > > 5339 > 0 > 1 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 99 > > > > > > 11766 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 99 > > > > > > 796 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 98 > > > > > > 3561 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 98 > > > > > > 10581 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 0 > 0 > 0 > 0 > 0 > 0 > 1 > 0 > 98 > > > > > > In short, the question is about to find a test to compare the occurrence of the > structures between the group higher than 100 and the group under 100. > > Thank you for your help, > C. > > > > Gesendet von Mail f?r Windows 10 > > Von: Suzen, Mehmet > Gesendet: mardi, 12 septembre 2017 13:24 > An: C?line L?scher > Cc: r-help at r-project.org > Betreff: Re: [R] comparition of occurrence of multiple variables between two > dataframes > > Do you have a simplified example with a code? It is not clear to me what do > you mean by tree but if you refer to tree data structure, maybe you could > change the data structure to tree > (https://cran.r-project.org/web/packages/data.tree/vignettes/data.tree.html) > and try to write comparison of two tree objects. It might be easier that > data.frame alone. > > On 12 September 2017 at 12:27, C?line L?scher <c-luescher at hispeed.ch> > wrote: > > Hi everyone, I need your help to solve a problem with occurrence and two > dataframes. > > I have an excel table of 15200 lines. Each line correspond to a tree analyzed > for its structures. I have all the structures in columns (48 structures). The > occurrence of these structures has been counted on every tree. For example, > the tree 12607 has 3 structures CV11, 1 structure IN12 and none (0) of the rest > of all the other structures. The very last column is the value given to the tree, > according to the structures found on it (each structure giving a number of point > to the tree by its presence on it). > > The question is: Are there some structures, or combination of structures, > which give a high value to the tree ? Of course, according to the value of each > structure, we can see which one has a higher value than the others (ex: > structure CV11 has a value of 15, structure IN12 has a value of 4). But what I > want to know is, if we take all the trees having a final value higher than 100 > (we create a new dataframe "data100"), and we compare with the trees having > a final value under 100 (we create another dataframe "data0"), can we find a > significant difference in the number and occurrence of structures found on > these trees? And which structure is related to trees with a higher value than > 100 ? > > For now, I have only a visual answer to the question. I did two boxplot of the > data100 and data0, and I have seen some diff?rences : 2 structures are only > found in the data100, which can be caracteristic of a final value higher than > 100. The problem is that I?m looking for a test to prove this. > > If you have any idea or proposition for solving this problem.. it will be great! > > Best wishes, > > C. > > > > > > Gesendet von Mail f?r Windows 10 > > > > > > [[alternative HTML version deleted]] > > > > ______________________________________________ > > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > > https://stat.ethz.ch/mailman/listinfo/r-help > > PLEASE do read the posting guide > > http://www.R-project.org/posting-guide.html > > and provide commented, minimal, self-contained, reproducible code. > > > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at r-project.org mailing list -- To UNSUBSCRIBE and more, see > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code.________________________________ Tento e-mail a jak?koliv k n?mu p?ipojen? dokumenty jsou d?v?rn? a jsou ur?eny pouze jeho adres?t?m. Jestli?e jste obdr?el(a) tento e-mail omylem, informujte laskav? neprodlen? jeho odes?latele. Obsah tohoto emailu i s p??lohami a jeho kopie vyma?te ze sv?ho syst?mu. Nejste-li zam??len?m adres?tem tohoto emailu, nejste opr?vn?ni tento email jakkoliv u??vat, roz?i?ovat, kop?rovat ?i zve?ej?ovat. Odes?latel e-mailu neodpov?d? za eventu?ln? ?kodu zp?sobenou modifikacemi ?i zpo?d?n?m p?enosu e-mailu. V p??pad?, ?e je tento e-mail sou??st? obchodn?ho jedn?n?: - vyhrazuje si odes?latel pr?vo ukon?it kdykoliv jedn?n? o uzav?en? smlouvy, a to z jak?hokoliv d?vodu i bez uveden? d?vodu. - a obsahuje-li nab?dku, je adres?t opr?vn?n nab?dku bezodkladn? p?ijmout; Odes?latel tohoto e-mailu (nab?dky) vylu?uje p?ijet? nab?dky ze strany p??jemce s dodatkem ?i odchylkou. - trv? odes?latel na tom, ?e p??slu?n? smlouva je uzav?ena teprve v?slovn?m dosa?en?m shody na v?ech jej?ch n?le?itostech. - odes?latel tohoto emailu informuje, ?e nen? opr?vn?n uzav?rat za spole?nost ??dn? smlouvy s v?jimkou p??pad?, kdy k tomu byl p?semn? zmocn?n nebo p?semn? pov??en a takov? pov??en? nebo pln? moc byly adres?tovi tohoto emailu p??padn? osob?, kterou adres?t zastupuje, p?edlo?eny nebo jejich existence je adres?tovi ?i osob? j?m zastoupen? zn?m?. This e-mail and any documents attached to it may be confidential and are intended only for its intended recipients. If you received this e-mail by mistake, please immediately inform its sender. Delete the contents of this e-mail with all attachments and its copies from your system. If you are not the intended recipient of this e-mail, you are not authorized to use, disseminate, copy or disclose this e-mail in any manner. The sender of this e-mail shall not be liable for any possible damage caused by modifications of the e-mail or by delay with transfer of the email. In case that this e-mail forms part of business dealings: - the sender reserves the right to end negotiations about entering into a contract in any time, for any reason, and without stating any reasoning. - if the e-mail contains an offer, the recipient is entitled to immediately accept such offer; The sender of this e-mail (offer) excludes any acceptance of the offer on the part of the recipient containing any amendment or variation. - the sender insists on that the respective contract is concluded only upon an express mutual agreement on all its aspects. - the sender of this e-mail informs that he/she is not authorized to enter into any contracts on behalf of the company except for cases in which he/she is expressly authorized to do so in writing, and such authorization or power of attorney is submitted to the recipient or the person represented by the recipient, or the existence of such authorization is known to the recipient of the person represented by the recipient.
Possibly Parallel Threads
- comparition of occurrence of multiple variables between two dataframes
- comparition of occurrence of multiple variables between two dataframes
- comparition of occurrence of multiple variables between two dataframes
- Help: ifelse selection for x,y coordinates
- Help: ifelse selection for x,y coordinates