Skip to Main Content
R Bioinformatics Cookbook
book

R Bioinformatics Cookbook

by Dan MacLean
October 2019
Intermediate to advanced content levelIntermediate to advanced
316 pages
9h 45m
English
Packt Publishing
Content preview from R Bioinformatics Cookbook

How it works...

The short and sweet code here is really powerful—and gives us a lot of analysis in a few commands.

In Step 1, initially, we load the libraries we require.

In Step 2, after loading the necessary libraries, we make a character vector, treefiles, which holds paths to the 20 trees we wish to use. The list.files() function that we use takes a filesystem path as its argument and returns the names of files it finds in that path. As treefiles is a vector, we can use it as the first argument to lapply().

In case you're not familiar with it, lapply() is an iterator function that returns an R list (hence, lapply()). Simply put, lapply() runs the function named in the second argument over the list of things in the first. The current ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

R Bioinformatics Cookbook - Second Edition

R Bioinformatics Cookbook - Second Edition

Dan MacLean
R Cookbook, 2nd Edition

R Cookbook, 2nd Edition

JD Long, Paul Teetor

Publisher Resources

ISBN: 9781789950694Supplemental Content