Introduction to R

BAN420 Introduction to R

Autumn 2024

  • Topics

    R is among the most powerful and widely used programming languages for data analysis in both science and businesses. R is a free open source tool, and new packages and functionalities are continuously being added.

    The course is intended for students without prior experience with R or other programming languages. In the course, you will:

    • set up your own R programming environment on your personal computer using Rstudio.
    • learn how to write, execute and modify R code and R scripts.
    • load data sets into R, create effective numerical and graphical summary statistics, and see how to use R to perform some common statistical analyses.
    • use programming techniques such as loops, conditionals and functions, to effectively solve practical and analytical issues that we encounter when working with data.

    After successfully completing the course, you will be comfortably able to use R as your tool for data analysis. Please note that BAN420 overlaps with the first part of BAN400. It is required to pass BAN420 in order to continue with BAN400.

  • Learning outcome

    Knowledge: On successful completion, the student can

    • understand the importance and usefulness of R as a tool in data analysis
    • understand the importance of reproducibility in data analysis.
    • understand the importance of documentation when creating scripts.

    Skills: On successful completion, the student can

    • use basic data structures (lists, arrays, matrices, vectors and data frames) as appropriate.
    • combine, merge and reshape data sets in R.
    • create and export convincing tables and figures for use in reports and presentations.
    • write reports using RMarkown.
    • use functions, loops, assignments, subsetting and conditionals in an R-script.
    • read and understand documentation of packages and functions.
    • independently resolve warnings, errors, and other basic programming issues

    General competence: On successful completion, the student can

    • work efficiently in R and RStudio.
    • conduct reproducible data analysis with R.

  • Teaching

    This course combines recorded lectures, programming tutorials and individual supervision. Lectures focus on methodological issues. In programming tutorials, the student will implement the methodologies using R.

  • Recommended prerequisites

    Basic statistical knowledge as provided by MET2

  • Credit reduction due to overlap

    BAN420 may be taken separately, or as the first part of BAN400.

    Please note that because BAN420 is identical with the first part of BAN400, there is a full credit reduction between the two courses. If you have already passed BAN420 and wish to take BAN400 at a later point, you will be awarded with a total of 7,5 ECTS for the two courses combined.

  • Compulsory Activity

    Approved homework assignments.

  • Assessment

    Assigned, individual term paper. The students will be given two weeks to work on the term paper.

  • Grading Scale


  • Computer tools

    R ( and RStudio ( and contributed packages as needed.

  • Literature

    Venables, Smith and the R Core Team (2017): An Introduction to R.

    Freely available from:


ECTS Credits
Teaching language


Course responsible

Associate Professor Håkon Otneim, Department of Business and Management Science (main course responsible).

Adjunct Associate Professor Ole Petter Moe-Hansen, Department of Business and Management Science.