Introduction to R


RlogoR is a free, powerful statistical and graphical tool which is available for most platforms (Windows, Mac, Linux, FreeBSD, etc.). More than that, it is open source, which means that one can freely modify and adapt R to fit a specific use (providing that one has enough knowledge in terms of programming, of course). In fact, R is not just a software for statistics; it is a language organized around “objects”, linked to data and functions. R is flexible, and it is rather easy to import data for text files (.txt, .csv, …).


Starting with R might be a bit confusing if you are used to softwares and programs that have a complete interface with icons, buttons, options, menus and ready-to-use functions.

Let’s take these first steps together.



Vectors are objects used in R to stored data elements such as numbers, text or logical values under a variable name. They allow you to simplify your work by saving many values under a unique name, create groups of data to be used, combined, modified, erased (…) at your will. They also allow you to perform simple or complex operations in a minimal amount of steps.


Vectors are not the only containers of your datasets (objects) in R. You will find out that you can also store lists of numbers/words, collections of data, matrices and so on under a name or variable. This will not only save your time and energy, but also prevent you from making mistakes and increase consistency in your calculations. Let’s see how to create these objects.


Dataframes are a central type of object when working with statistics in R. They are actually simple tables or two-dimensional matrices arrays which contain your data, arranged in a rather specific manner. Here we’ll see what they are made of, how to handle them and how to make the best of it to analyse your precious data.


If you have collected your data in MS Excel or any other program, you may want to transfer it to R in the safest way. Here are a couple of posts on, for example, how to export from Excel to a CSV file and then how to import from the CSV file into R. Other ways to export/import will be also described here.



This section provides you few a few useful or frequently used functions that may make your work quicker or at least easier. Making series, handling vectors and objects…




It is time to start drawing charts and visualize your data in a more graphical manner. As you will see in this section, R is powerful and give you the chance to do what you want, providing that you know the language. They are plenty of functions and arguments to set up all kind of items. However, before getting fancy and making impressive charts, it is necessary to get the basics.


R is definitely a powerful tool when it comes to making plots and charts. Here we will quickly review some of the most common charts that you can create in R via a series of examples. It is not the purpose of this page to show you how to do everything and anything in terms of chart making; we rather focus on getting you started with different types of charts.

  Fant du det du lette etter? Did you find this helpful?
[Average: 4]