Using custom R functions and map, map_dfr, and map2 to create multiple ROC curves (CC123)

  Рет қаралды 2,922

Riffomonas Project

Riffomonas Project

Күн бұрын

Пікірлер: 10
@Riffomonas
@Riffomonas 3 жыл бұрын
What questions do you have about writing your own functions in R? How about questions for using purrr's map functions?
@nastassiashkliarava974
@nastassiashkliarava974 2 жыл бұрын
Hi. Very cool video, informative. There is a question, what is meant here by set.seed(). Thank you
@Riffomonas
@Riffomonas 2 жыл бұрын
​@@nastassiashkliarava974 Hi Nastassia! If I recall correctly... The placement of the data on the x-axis within each group is random with geom_jitter. The set.seed function makes a random process reproducible. By setting the seed to a constant value, the random numbers generated by the random number generator will be the same each time the script is run. Try running set.seed(1); runif(10); runif(10). You'll see that the second 10 numbers are different from the first. But if you run set.seed(1); runif(10) the 10 numbers will be the same as the first 10
@nastassiashkliarava974
@nastassiashkliarava974 2 жыл бұрын
@@Riffomonas Yeah, so set.seed() I can take any number? Well, then you can somehow tell me about clustering and how to do it better, otherwise, there are so many questions. Thank you so much
@Riffomonas
@Riffomonas 2 жыл бұрын
@@nastassiashkliarava974 That's right - it can take any number. Talking about clustering is beyond the scope of what I can do in these comment threads :) If you're asking about clustering 16S rRNA gene sequences, then I'd encourage you to check out my past papers and consider taking the next mothur workshop riffomonas.org/workshops/
@sancaixie1750
@sancaixie1750 Жыл бұрын
Thanks for creating so many very informative R tutorials! I am also interesting in reading your results, especially in Porphyromonas and peptostreptococcus genera, which are associated with periodontitis. Have you published the results you are discussing in this video?
@hansmeiser6078
@hansmeiser6078 Жыл бұрын
It's the first time in 6 years, that I heard of an index-option in map_dfr(1:2,...). I found nothing about it in the docs. Where can I get the full parameter-list of the map functions? By the way... this works: sampleDf
@Riffomonas
@Riffomonas Жыл бұрын
Thanks for watching! Here's the documentation page for the map functions: purrr.tidyverse.org/reference/map.html
@hansmeiser6078
@hansmeiser6078 Жыл бұрын
@@Riffomonas Thank you, but they dont mention the run index (1:2). Where did you got this information?
@Riffomonas
@Riffomonas Жыл бұрын
@@hansmeiser6078 Sorry it's been a while since I made this video so I'm not able to find where I did run index (1:2). The first slot in the map functions defaults to the .x argument. So if we did .x=1:2 we would be giving it a vector of values. The resason your map2 function wouldn't work is because you are setting .x and .y, which are the first two arguments to the function. I suspect it might think 1:2 is the function that you are trying to execute rather than the ~doRoll
How to run your R code in parallel with the furrr package (CC127)
16:29
Riffomonas Project
Рет қаралды 3,8 М.
Dad gives best memory keeper
01:00
Justin Flom
Рет қаралды 21 МЛН
Nastya and balloon challenge
00:23
Nastya
Рет қаралды 31 МЛН
Nurse's Mission: Bringing Joy to Young Lives #shorts
00:17
Fabiosa Stories
Рет қаралды 19 МЛН
The purrr package map functions in the Tidyverse; Learn R Video 11
16:31
DesignCodeDebugRepeat
Рет қаралды 512
How to purrr
17:46
Equitable Equations
Рет қаралды 10 М.
🚨 YOU'RE VISUALIZING YOUR DATA WRONG. And Here's Why...
17:11
Adam Finer - Learn BI Online
Рет қаралды 140 М.
Introduction to building machine learning models in R with mikropml (CC124)
30:10
ROC Curve & Area Under Curve (AUC) with R - Application Example
19:40
Dr. Bharatendra Rai
Рет қаралды 103 М.
How to Use lapply, sapply and mapply in R
7:45
DataDaft
Рет қаралды 39 М.