R in Finance and Economics
eBook - ePub

R in Finance and Economics

A Beginner's Guide

Abhay Kumar Singh, David Edmund Allen

Partager le livre
  1. 264 pages
  2. English
  3. ePUB (adapté aux mobiles)
  4. Disponible sur iOS et Android
eBook - ePub

R in Finance and Economics

A Beginner's Guide

Abhay Kumar Singh, David Edmund Allen

DĂ©tails du livre
Aperçu du livre
Table des matiĂšres
Citations

À propos de ce livre

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.

Foire aux questions

Comment puis-je résilier mon abonnement ?
Il vous suffit de vous rendre dans la section compte dans paramĂštres et de cliquer sur « RĂ©silier l’abonnement ». C’est aussi simple que cela ! Une fois que vous aurez rĂ©siliĂ© votre abonnement, il restera actif pour le reste de la pĂ©riode pour laquelle vous avez payĂ©. DĂ©couvrez-en plus ici.
Puis-je / comment puis-je télécharger des livres ?
Pour le moment, tous nos livres en format ePub adaptĂ©s aux mobiles peuvent ĂȘtre tĂ©lĂ©chargĂ©s via l’application. La plupart de nos PDF sont Ă©galement disponibles en tĂ©lĂ©chargement et les autres seront tĂ©lĂ©chargeables trĂšs prochainement. DĂ©couvrez-en plus ici.
Quelle est la différence entre les formules tarifaires ?
Les deux abonnements vous donnent un accĂšs complet Ă  la bibliothĂšque et Ă  toutes les fonctionnalitĂ©s de Perlego. Les seules diffĂ©rences sont les tarifs ainsi que la pĂ©riode d’abonnement : avec l’abonnement annuel, vous Ă©conomiserez environ 30 % par rapport Ă  12 mois d’abonnement mensuel.
Qu’est-ce que Perlego ?
Nous sommes un service d’abonnement Ă  des ouvrages universitaires en ligne, oĂč vous pouvez accĂ©der Ă  toute une bibliothĂšque pour un prix infĂ©rieur Ă  celui d’un seul livre par mois. Avec plus d’un million de livres sur plus de 1 000 sujets, nous avons ce qu’il vous faut ! DĂ©couvrez-en plus ici.
Prenez-vous en charge la synthÚse vocale ?
Recherchez le symbole Écouter sur votre prochain livre pour voir si vous pouvez l’écouter. L’outil Écouter lit le texte Ă  haute voix pour vous, en surlignant le passage qui est en cours de lecture. Vous pouvez le mettre sur pause, l’accĂ©lĂ©rer ou le ralentir. DĂ©couvrez-en plus ici.
Est-ce que R in Finance and Economics est un PDF/ePUB en ligne ?
Oui, vous pouvez accĂ©der Ă  R in Finance and Economics par Abhay Kumar Singh, David Edmund Allen en format PDF et/ou ePUB ainsi qu’à d’autres livres populaires dans Volkswirtschaftslehre et Statistik fĂŒr Volks- & Betriebswirtschaft. Nous disposons de plus d’un million d’ouvrages Ă  dĂ©couvrir dans notre catalogue.

Informations

Éditeur
WSPC
Année
2016
ISBN
9789813144484

Chapter 1

Introduction

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.
image
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.
image
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,...

Table des matiĂšres