or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Do you want to remove this version name and description?
Syncing
xxxxxxxxxx
GPS Skills Course Series - R (2023Winter)
Course Details
Dates: January 30th, 2023 - February 17th, 2023
Days: Tuesday/Thursday
Time: 2-3:20pm
Course Agenda:
(Github page)
Software Installation:
*Refer to Canvas course software download files.
Lesson Data (download)
*Refer to Canvas course data download files.
NOTES:
A copy of the instructor live session notes will be uploaded in canvas at the end of session lesson.
(Include only for Python course)Jupyterlab will be used for the lessons
[m] Markdown cell = notes
[#]also works in code cell for notes
[b] = add cell below [a] is above
[r]Raw cells cannot have text edits
https://www.markdownguide.org/getting-started/
https://www.markdownguide.org/basic-syntax/
End
Session 1
Name (Last, First) / Email
Notes
You can use R as a calculator
Variables and assignments
use assignment operator
<-
to assign values to variablesSession 1 Questions:
Please enter any questions not answered during live session here:
1.
End Session 1
Session 2
Name (Last, First) / Email
Notes:
creating a csv and saving in a data folder
5 main data types in R
##############################
Quick clarification for converting variable types.
Suppose you have a mixed variable type recorded as presented in the class:
R is going to recognize that as
character type
because of "a".If you import the csv file with this type of mixed variable types, and if you use the option
stringAsFactors = TRUE
, then yourcharacter type
of variable will be recognized asfactor
, which is equivalent tointeger type
of variable.We can convert the
weight
back tonumeric type
using theas.numeric()
function, but because R recognizes theweight
variable as factor, the converted output would be 1, 2, 3, in increasing order. For our example, 2.1 = 1, 3.2 = 2, 5.0 = 3, and "a" = 4.However, if you selected
stringAsFactros = FALSE
option, then R recognizes the weight variable ascharacter type
, and converting that variable to numeric would produceNA
for mismatching type.Please see table for a brief summary:
as.numeric()
Session 2 Questions:
Please enter any questions not answered during live session here:
1.
End Session 2
Session 3
Name (Last, First) / Email
Doe, John / jdoe@ucsd.edu (example)
Nakamura, Masaki / m1nakamura@ucsd.edu
Yamada, Sohei / syamada@ucsd.edu
Tianning, Lan / tilan@ucsd.edu
Phrasavath, Bonaly / bphrasav@ucsd.edu
Orosz, Stephanie / sorosz@ucsd.edu
Nogueda, Lesley/lnogueda@ucsd.edu
Paula Jaramillo/pjaramillo@ucsd.edu
Pykurel, Himanshu/ hpykurel@ucsd.edu
Cho, Harrison / hhc002@ucsd.edu
Artan, Warsan / wartan@ucsd.edu
ilaria simmen
Lascano, Dayra / dlascano@ucsd.edu
Chen, Wenxin / wec027@ucsd.edu
Groper, Danielle / dgroper@ucsd.edu
Coyle, Jackson / jacoyle@ucsd.edu
Romstadt, Lisa / lromstadt@ucsd.edu
Tsuru, Yutaro / ytsuru@ucsd.edu
Cuevas, Christopher/ccuevas@ucsd.edu
Xuran, Wang / xuw028@ucsd.edu
Chu, Jordan / j1chu@ucsd.edu
Yamakawa, Daisuke / dayamakawa@ucsd.edu
Zhiyuan, Chi / z1chi@ucsd.edu
Tan,Jingyi / j3tan@ucsd.edu
Yuxin Guo / yug041@ucsd.edu
Leung, Taysia/ t3leung@ucsd.edu (Asynchronous Video)
Ahluwalia, Gurkriti / gahluwalia@ucsd.edu
Notes
importing data
exploring data
Challenge 1
answer:
challenge 2
answer:
#selecting data by cutoff
adding wrong length vector
add new row
factors
dplyr
Session 3 Questions:
Please enter any questions not answered during live session here:
1.
End Session 3
Session 4
Name (Last, First) / Email
NOTES
loading libraries
loading data
converting wide to long format
Session 4 Questions:
Please enter any questions not answered during live session here:
1.
End Day 4
Session 5
Name (Last, First) / Email
Doe, John / jdoe@ucsd.edu (example)
Nakamura, Masaki / m1nakamura@ucsd.edu
Phrasavath, Bonaly / bphrasav@ucsd.edu
Lascano, Dayra / dlascano@ucsd.edu
Ye, Yuan / yeyuan@ucsd.edu
Tianning , Lan / tilan@ucsd.edu
Tsuru, Yutaro / ytsuru@ucsd.edu
Chen, Wenxin / wec027@ucsd.edu
Coyle, Jackson / jacoyle@ucsd.edu
Tan, Jingyi/ j3tan@ucsd.edu
Groper, Danielle / dgroper@ucsd.edu
Artan, Warsan / wartan@ucsd.edu
Cuevas, Christopher/ccuevas@ucsd.edu
Xuran, Wang / xuw028@ucsd.edu
Yuxin Guo / yug041@ucsd.edu
Yamakawa, Daisuke / dayamakawa@ucsd.edu
Leung, Taysia/ t3leung@ucsd.edu (Asynchronous Video)
Chu, Jordan / j1chu@ucsd.edu
Ahluwalia, Gurkriti / gahluwalia@ucsd.edu
notes
using ggplot
layers
transformation and stats
changing alpha
#multi-pannel figures using face-wrap
useful ggplot cheatsheet:
https://statsandr.com/blog/files/ggplot2-cheatsheet.pdf
Session 5 Questions:
Please enter any questions not answered during live session here:
1.
End Day 5
Session 6
Name (Last, First) / Email
Doe, John / jdoe@ucsd.edu (example)
Pykurel, Himanshu / hpykurel@ucsd.edu
Lascano, Dayra / dlascano@ucsd.edu
Nogueda, Lesley /
lnogueda@ucsd.edu
Nakamura, Masaki / m1nakamura@ucsd.edu
Phrasavath, Bonaly / bphrasav@ucsd.edu
Tsuru, Yutaro / ytsuru@ucsd.edu
Artan, Warsan / wartan@ucsd.edu
Groper, Danielle / dgroper@ucsd.edu
Cuevas, Christopher/ccuevas@ucsd.edu
Xuran, Wang / xuw028@ucsd.edu
Yuxin Guo / yug041@ucsd.edu
Coyle, Jackson / jacoyle@ucsd.edu
Chen, Wenxin / wec027@ucsd.edu
Yamakawa, Daisuke / dayamakawa@ucsd.edu
Leung, Taysia/ t3leung@ucsd.edu (Asynchronous Video)
Chu, Jordan / j1chu@ucsd.edu
Ahluwalia, Gurkriti / gahluwalia@ucsd.edu
download data directly from a link.
use this google drive link to download the 'est.csv' file
Notes
using .rmd rnotebook
Create and rnotebook file:
file menu/new file/r notebook
#filter the country to plot
Session 6 Questions:
Please enter any questions not answered during live session here:
1.
End Day 6