Training on Educational Research and Statistical Analysis for Teachers - Sessions 8–9 R Practice

힘센캥거루
2025년 12월 27일(수정됨)
1
9

This part was hands-on practice with R.

We tried out simple calculations and using libraries.

For example, let’s say we have the following Python code.

def add(a, b):
	return a + b
x = 1
y = 2
sum(x, y)

If we convert this to R, it looks like this.

add <- function(a, b){
	return a + b
}
x <- 1
y <- 2
sum(x, y)

And the basic data types are as follows.

Data type

Example

Description

Numeric

x <- 10

double by default

Character

name <- "R"

Strings use quotation marks

Logical

flag <- TRUE

TRUE / FALSE

Vector

v <- c(1,2,3)

Basic data structure in R

List

lst <- list(a=1, b="hi")

Can contain different types

Data frame

df <- data.frame(x=1:3, y=c("a","b","c"))

Table-like form

Instead of lists, you use the vector type, and you can perform operations on all of its values at once.

x <- c(1,2,3)
x + 1     # [1] 2 3 4
x * 2     # [1] 2 4 6
x == 2    # [1] FALSE TRUE FALSE

At one point we loaded csv and sav files, and I was surprised that the function names were very similar to those in pandas.

That made me wonder if it wouldn’t be fine to just analyze everything with Python instead of using R, but according to ChatGPT it’s still good to learn R.

Training on Educational Research and Statistical Analysis for Teachers - Sessions 8–9 R Practice-1

I feel like once I do one proper data analysis project, I’ll get the hang of it.

관련 글

2026년 동국대학교 미래사회 교원역량 강화 포럼 오프라인 참여 후기
2026년 동국대학교 미래사회 교원역량 강화 포럼 오프라인 참여 후기
어느 선생님이 재미있어 보이는 연수를 하나 소개시켜 주셨다.동국대에서 진행하는 AI 관련 연수였다.AI인 것도 좋인데 연수가 호텔에서?이건 무조건 가야 한다 싶었다.해당일 연수가 열리자 마자 신청해서 오프라인으로 참석하게 되었다.1. 앰배서더 서울 풀만 호텔처음에는 접...
Global Skilled Crafts Promotion Institute Special Field Training – Woodworking Workshop Review
Global Skilled Crafts Promotion Institute Special Field Training – Woodworking Workshop Review
A teacher I know told me there was a residential woodworking workshop being held in Incheon.And among the options, they said I absolutely had to take...
A Beginner’s Hacking Guide for Aspiring White-Hat Hackers – First Impressions of “A Taste of Hacking”
A Beginner’s Hacking Guide for Aspiring White-Hat Hackers – First Impressions of “A Taste of Hacking”
The most important thing when running a home server was security.No matter how nicely I built the website features, once I got hit by hacking attempts...
Training on Educational Research and Statistical Analysis for Teachers – Summary of Sessions 21–30 and Reflections
Training on Educational Research and Statistical Analysis for Teachers – Summary of Sessions 21–30 and Reflections
Today I’d like to write down what I remember from sessions 21–30 of the educational research and statistical analysis course for teachers, along with...
Educational Research and Statistical Analysis Training for Teachers - Collection of R Practices from Sessions 13–20
Educational Research and Statistical Analysis Training for Teachers - Collection of R Practices from Sessions 13–20
Previously, I used to wonder whether I really needed to learn R when I already knew Python.Through this training, I realized that there’s actually no...
Teacher Training in Educational Research and Statistical Analysis – Sessions 10–12: Coefficient of Determination, Multiple Regression Analysis, etc.
Teacher Training in Educational Research and Statistical Analysis – Sessions 10–12: Coefficient of Determination, Multiple Regression Analysis, etc.
I wrote a reflection after each session every day, but with writing student records and doing this as well, I ended up having to cut down on sleep eve...

댓글을 불러오는 중...