-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ef3b87b
commit 3c8d0da
Showing
1 changed file
with
19 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
id: 1fm4dncuybvd5vqj931b01n | ||
title: Coding tips for the R programming language | ||
desc: '' | ||
updated: 1692464690591 | ||
created: 1692464253688 | ||
--- | ||
|
||
# Load R script into session | ||
|
||
To load the contents of an R script, you can use the `source()` function¹. This function reads the specified R script file and runs the code contained within it. For example, if you have an R script named `my_script.R` in your working directory, you can load its contents by running the following command in the R console: `source("my_script.R")`¹. This will execute all of the code contained within the `my_script.R` file¹. | ||
|
||
|
||
**Source:** [Conversation with Bing](https://sl.bing.net/f9X2XdJtdJc), 19/8/2023 | ||
|
||
## References | ||
|
||
* (1) Run R script from command line - Stack Overflow. https://stackoverflow.com/questions/18306362/run-r-script-from-command-line. | ||
* (2) load function - RDocumentation. https://www.rdocumentation.org/packages/base/versions/3.6.2/topics/load. |