Operating on files with R: copy and rename
Nowadays, routinary operations on files, such as renaming or copying, are performed with some mouse clicks. Sometimes, it is useful perform this operations in batch. Linux users perform this operations through the shell. Also Windows users can use the shell, but there are also a lot of utilities that simplify these operations.
Why someone should use R to copy or rename a (lot of) file(s)?
Continue reading
Learning RStudio for R Statistical Computing

"Learning RStudio for R Statistical Computing" will teach you how to quickly and efficiently create and manage statistical analysis projects, import data, develop R scripts, and generate reports and graphics. R developers will learn about package development, coding principles, and version control with RStudio.
This book will help you to learn and understand RStudio features to effectively perform statistical analysis and reporting, code editing, and R development.
The book starts with a quick introduction where you will learn to load data, perform simple analysis, plot a graph, and generate automatic reports. You will then be able to explore the available features for effective coding, graphical analysis, R project management, report generation, and even project management.
Book review
Maps in R: choropleth maps
This is the third article of the Maps in R series. After having shown how to draw a map without placing data on it and how to plot point data on a map, in this installment the creation of a choropleth map will be presented.
A choropleth map is a thematic map featuring regions colored or shaded according to the value assumed by the variable of interest in that particular region.
Maps in R: Plotting data points on a map
In the introductory post of this series I showed how to plot empty maps in R.
Today I'll begin to show how to add data to R maps. The topic of this post is the visualization of data points on a map.
Maps in R: Introduction - Drawing the map of Europe
This post is a brief follow-up to a question that appeared some time ago on the “The R Project for Statistical Computing” LinkedIn group, which I’m reporting here:
How can I draw a map of MODERN Europe?
Hi, I'm trying to draw a map of modern Europe but I've found only maps of twenty years ago, with Yugoslavia and Czechoslovakia still united!!!
Does anyone know where I can get a more recent map to be employed with packages such as 'sp' or 'maps'?
Thank you very much!
Two different solutions to the above question will be provided here, using two different R packages.
Function Closures and S4 Methods
This brief tutorial illustrates how to combine S4 object oriented capabilities with function closures in order to develop classes with built in methods. Thanks to Hadley Wickham for the great contribution of material and tutorials made available on the web and to Bill Venables and Stefano Iacus for their kind reviews.
Genome annotation with NCBI2R
It's very convenient manage data with R: you can import your dataset, you could find many packages which respond to your needs, then you could plot your results.
However it could be very bothersome retrieve the data from online databases. You need to use the specific API and maybe write your scripts using a new programming language, then you have to convert your data in a table format and finally import them with R.
Continue reading
Power and Sample Size Analysis: Z test
Abstract
This article provide a brief background about power and sample size analysis. Then, power and sample size analysis is computed for the Z test.
Next articles will describe power and sample size analysis for:
- one sample and two samples t test;,
- p test, chi-square test, correlation;
- one-way ANOVA;
- DOE
.
Finally, a PDF article showing both the underlying methodology and the R code here provided, will be published.
Divide or Mix. Flexible Approaches to Data Analysis
A very interesting paradigm in data analysis comes from the necessity to model data where it is difficult to think of a single global function to be capable to represent adequately the data.
We could see a spectrum of models going from the global statistical model, with a single function and associated probability distribution, to the decision tree fitting a set of constants at each leaf of the tree.
This articles focuses in models which combine the two extrema to yield a more parsimonious solution and, at the same time, try to get the best of both approaches.
We shall present two of the best representatives of the above mentioned approach, the party package which combines the decision tree with local models fitted at the leaves of the tree and the Flexmix package, implementing a solution based on a mixture of models (a soft approach).
GenABEL: an annoying error after the import of PLINK data format
In the previous post we saw how much convenient could be GenABEL in the management of genotypic/phenotypic data.
We introduced the import of genotypic data from an Illumina format file:
> convert.snp.illumina(inf = "gen.illu", out = "gen.raw", strand = "file")
but what happens if you're analysing your data with PLINK, the open source toolset for GWAS?
