Monday, April 06, 2015

R: How to get current working directory and change it

If you are working on a R project, and you wish to load/save your data in some file, it is important to know which directory you are currently working in, so that you can easily browse or save your data to that directory or may be change it to a specific location. Here are the list of commands to get you going :

> getwd()
[1] "C:/Users/parag/Documents"
> ?setwd
> setwd("X:/Share")
> getwd()
[1] "X:/Share"
> 

No comments:

Section 80C TMT 2023(PA) – Standard Deduction amounting to a maximum of Rs 8670 under IT rule

With the recently concluded Tax filing season (which if I may draw parallel to the Christmas holiday season enjoyed by one and all), Indians...