R in Finance and Economics
eBook - ePub

R in Finance and Economics

A Beginner's Guide

Abhay Kumar Singh, David Edmund Allen

  1. 264 pagine
  2. English
  3. ePUB (disponibile sull'app)
  4. Disponibile su iOS e Android
eBook - ePub

R in Finance and Economics

A Beginner's Guide

Abhay Kumar Singh, David Edmund Allen

Dettagli del libro
Anteprima del libro
Indice dei contenuti

Informazioni sul libro

This book provides an introduction to the statistical software R and its application with an empirical approach in finance and economics. It is specifically targeted towards undergraduate and graduate students. It provides beginner-level introduction to R using RStudio and reproducible research examples. It will enable students to use R for data cleaning, data visualization and quantitative model building using statistical methods like linear regression, econometrics (GARCH etc), Copulas, etc. Moreover, the book demonstrates latest research methods with applications featuring linear regression, quantile regression, panel regression, econometrics, dependence modelling, etc. using a range of data sets and examples.

Domande frequenti

Come faccio ad annullare l'abbonamento?
È semplicissimo: basta accedere alla sezione Account nelle Impostazioni e cliccare su "Annulla abbonamento". Dopo la cancellazione, l'abbonamento rimarrà attivo per il periodo rimanente già pagato. Per maggiori informazioni, clicca qui
È possibile scaricare libri? Se sì, come?
Al momento è possibile scaricare tramite l'app tutti i nostri libri ePub mobile-friendly. Anche la maggior parte dei nostri PDF è scaricabile e stiamo lavorando per rendere disponibile quanto prima il download di tutti gli altri file. Per maggiori informazioni, clicca qui
Che differenza c'è tra i piani?
Entrambi i piani ti danno accesso illimitato alla libreria e a tutte le funzionalità di Perlego. Le uniche differenze sono il prezzo e il periodo di abbonamento: con il piano annuale risparmierai circa il 30% rispetto a 12 rate con quello mensile.
Cos'è Perlego?
Perlego è un servizio di abbonamento a testi accademici, che ti permette di accedere a un'intera libreria online a un prezzo inferiore rispetto a quello che pagheresti per acquistare un singolo libro al mese. Con oltre 1 milione di testi suddivisi in più di 1.000 categorie, troverai sicuramente ciò che fa per te! Per maggiori informazioni, clicca qui.
Perlego supporta la sintesi vocale?
Cerca l'icona Sintesi vocale nel prossimo libro che leggerai per verificare se è possibile riprodurre l'audio. Questo strumento permette di leggere il testo a voce alta, evidenziandolo man mano che la lettura procede. Puoi aumentare o diminuire la velocità della sintesi vocale, oppure sospendere la riproduzione. Per maggiori informazioni, clicca qui.
R in Finance and Economics è disponibile online in formato PDF/ePub?
Sì, puoi accedere a R in Finance and Economics di Abhay Kumar Singh, David Edmund Allen in formato PDF e/o ePub, così come ad altri libri molto apprezzati nelle sezioni relative a Economics e Statistics for Business & Economics. Scopri oltre 1 milione di libri disponibili nel nostro catalogo.



Chapter 1


R is an open source software package and environment for statistical computing and graphics. The R language has received a lot of attention in the last five years or so particularly with its growing use by Statisticians and data miners for their empirical analysis and software development. R started as a freely available implementation of the S programming language. R was created by Ross Ihaka and Robert Gentleman, of the University of Auckland, New Zealand, and now, R is developed by the R Development Core Team. R can be considered as a different implementation of S. There are some important differences, but much code written for S runs unaltered under R.
The official R website http://www.r-project.org/ provides the best description and explanation for R. This section and the section following in the introduction to R are majorly adopted from the R website.
According to Wikipedia, “R is a free software programming language and a software environment for statistical computing and graphics. The R language is widely used among Statisticians and data miners for developing statistical software and data analysis. Polls and surveys of data miners suggest R’s popularity has increased substantially in recent years”.
By design, R provides the possibility of further computations (methods) on the results (objects) of a statistical procedure. Also the graphical capabilities of R facilitate methods as simple as plot (x, y) to very specific and fine control over the output. The fact that R is based on a formal computer language gives it tremendous flexibility. Other systems present simpler interfaces in terms of menus and forms, but often the apparent user-friendliness turns into a hindrance in the longer run.

1.1Why Should We Learn R?

The growth in the number of R users in recent years has indicated that researchers around the world are either using R or will use it at some point. There are several advantages to using R for statistical computing other than its open source and doesn’t cost anything. The benefits of R for an introductory student and instructors are
R is free.
R is open source and runs on UNIX, Windows and Macintosh, so it can be used on multiple platforms.
R has an excellent built-in help system and also various online help pages including mailing lists and boards.
R has excellent graphing capabilities which are customisable.
R’s language has a powerful, easy to learn syntax with many built-in statistical functions which are provided by default built-in packages.
R is a computer programming language. It is easier for programmers to learn it and its intuitive enough for beginners.
R provides specific functions bundled in user created packages for a particular field. This makes it easier for an applied researcher to use these functions rather than having to reinvent the wheel.
R follows a type inference coding structure which enables the automatic deduction of the type of an expression in R. For example, a string is identified as character and need not be explicitly declared before. R provides a wide variety of statistical and graphical techniques, including:
Linear and nonlinear modelling,
Univariate and multivariate statistics,
Classical statistical tests,
Time series analysis/econometrics,
Simulation and modelling,
Data mining-classification, clustering, etc.,
For computationally intensive tasks, C, C++, and Fortran code can be linked and called at run time.
R is easily extensible through functions and extensions, and the R community is noted for its active contributions in terms of packages. R has over 8000 packages with new packages added more frequently than any other statistical software. The R command below should run with an Internet connection. We will discuss how to setup proxy on work computers later.
Although R is available for Macintosh, Unix and Linux as well, we will use R on windows in this book. In most cases, the examples and codes in this text can be used for other operating system unaltered.
Other statistical packages, such as SPSS, GRETL and Minitab, provide point-and-click graphical-user interfaces (GUIs), but R is command-oriented. Although basic R is command/script based and provides a basic script editor, GUI capabilities can be added to the R interface using packages like Rcmdr. The R interface provides a basic GUI with a console to type commands and a script editor to write scripts. It also provides a few other functionalities like loading packages, clearing workspace, changing directory, etc. Users normally type commands at a command prompt in the console or as a script in the R script editor to get a desired output.
RStudio, an integrated development environment (IDE) (http://www.rstudio.com/ide/) is a powerful and productive user interface for R. RStudio provides various additional functionalities to the basic R interface which makes RStudio the choice of IDE in this book. We will now discuss how to get R and RStudio along with installing them on windows1 in the following subsections while providing more details about the R Environment.

1.2R: Getting Started

1.2.1Installing R on windows

The latest version of R can be downloaded from the CRAN page https://cloud.r-project.org/bin/windows/base/. CRAN is a network of ftp and web servers around the world which store identical, up-to-date versions of code and documentation for R. The list of available CRAN mirrors can be found at http://cran.r-project.org/mirrors.html. The page also provides some instructions and FAQs on R installation. The R-base is an executable package which can be easily installed on a windows machine with Administrative privileges. As stated earlier R comes with a basic GUI, which has a basic source code editor and a console window for command input.
Figure 1.1: R GUI (Windows)
The R GUI in windows looks like as shown in Figure 1.1.

1.2.2RStudio: A better way to run R

RStudio is an IDE and is a powerful and productive user interface for R. It is freely available, and works on Windows, Mac, and Linux. RStudio also comes in a server version that can be used to run R on a remote web server. In that case,...

Indice dei contenuti

  1. Cover
  2. Halftitle
  3. Title
  4. Copyright
  5. About the Author
  6. Preface
  7. Supplementary Material
  8. Contents
  9. 1. Introduction
  10. 2. Data Objects in R
  11. 3. Data Handling in R
  12. 4. R Programming and Control Flow
  13. 5. Data Exploration
  14. 6. Graphics in R
  15. 7. Regression Analysis-I
  16. 8. Regression Analysis-II
  17. 9. Time Series Analysis
  18. 10. Extreme Value Theory Modelling
  19. 11. Introduction to Multivariate Analysis using Copulas
  20. Bibliography
  21. Index
Stili delle citazioni per R in Finance and Economics

APA 6 Citation

Singh, A. K., & Allen, D. E. (2016). R in Finance and Economics ([edition unavailable]). World Scientific Publishing Company. Retrieved from https://www.perlego.com/book/853267/r-in-finance-and-economics-a-beginners-guide-pdf (Original work published 2016)

Chicago Citation

Singh, Abhay Kumar, and David Edmund Allen. (2016) 2016. R in Finance and Economics. [Edition unavailable]. World Scientific Publishing Company. https://www.perlego.com/book/853267/r-in-finance-and-economics-a-beginners-guide-pdf.

Harvard Citation

Singh, A. K. and Allen, D. E. (2016) R in Finance and Economics. [edition unavailable]. World Scientific Publishing Company. Available at: https://www.perlego.com/book/853267/r-in-finance-and-economics-a-beginners-guide-pdf (Accessed: 14 October 2022).

MLA 7 Citation

Singh, Abhay Kumar, and David Edmund Allen. R in Finance and Economics. [edition unavailable]. World Scientific Publishing Company, 2016. Web. 14 Oct. 2022.