Positron IDE doing Data Analysis with R (Public Beta)
TheCoatlessProfessor TheCoatlessProfessor
883 subscribers
3,183 views
0

 Published On Jul 1, 2024

Timeline

00:00 Intro
00:25 Select R as the interpreter from the upper right corner.
00:40 View the usual R startup message in the lower-left window.
00:50 Discussion on keyboard shortcuts.
02:00 Enable RStudio keyboard shortcut mapping in Positron.
02:47 Create a new R Project in Positron for data analysis.
04:10 Discuss setting the working directory correctly in the R Project.
05:02 Save R Script using CMD + S or CTRL + S.
05:45 Mouse over a file to see its file system path.
06:02 Close the explorer bar for maximum screen space.
06:45 Start coding in an R Script.
07:47 Use CMD + ENTER or CTRL + ENTER to send code from the R script to the console.
09:04 Mouse over URLs and hold CMD or CTRL to make them clickable.
10:00 Discuss session and variables holding code results.
10:42 Observe downloaded data in the R project directory using the file explorer.
11:30 Explore what a Data Frame looks like under the session's Data subheader.
12:00 Trigger the interactive data explorer.
12:27 Identify variable types (pound sign (#) for numbers, (A) for strings/factors).
13:50 Sort data within the interactive data viewer.
15:00 Apply a filter to the data.
16:00 Hide/clear filters.
16:31 Expand the right-hand side to see additional text like variable type and number of observations.
19:00 Modify the dataframe to include a new derived variable that is a factor.
19:40 Open the Data Viewer using the View() function.
20:55 Handle an error with a missing package.
22:36 Graph with ggplot2.
24:35 Explore the plot area of Positron.
26:57 Demonstrate Plotly with ggplot2.
28:31 Count with dplyr.
29:03 Use the pipe operator shortcut (CMD + SHIFT + M or CTRL + SHIFT + M).
30:21 Create a gt() table with the count data.
31:07 Explore help documentation with Positron.
31:38 Run examples to execute static examples within the help window.
31:58 Handle a hiccup when viewing the package's index HTML page.
32:06 Final thoughts.

Summary ---

For this video, we take a look at the Positron IDE's R session features. We focus on using an R project and a single R script file. We explore different portions of the interface, including the famed interactive data viewer.

This video covers a large gambit from setting up keyboard shortcuts similar to what is available in RStudio to creating interactive plots using the {plotly} package.

Links ---

Positron Keyboard Shortcuts Wiki Page

https://github.com/posit-dev/positron...

Data location:

https://github.com/coatless/raw-data/...

Relevant script file:

https://github.com/coatless-videos/po...

Positron Interactive Data Viewer Wiki Page

https://github.com/posit-dev/positron...

Positron can be obtained from:

https://github.com/posit-dev/positron


Version information ----

This was demonstrated on:

Positron Version: 2024.06.1 (Universal) build 27
Code - OSS Version: 1.90.0
Commit: a893e5b282612ccb2200102957ac38d3c14e5196
Date: 2024-06-26T02:08:06.673Z
Electron: 29.4.0
Chromium: 122.0.6261.156
Node.js: 20.9.0
V8: 12.2.281.27-electron.0
OS: Darwin arm64 23.5.0

#positron #posit #rstudio #ggplot2 #plotly #gt #csv

show more

Share/Embed