s4_method.r

Rマスター

Explorer

C40
C++40
C#40
Dart40
Go40
Java40
JavaScript40
Kotlin40
Objective-C40
Perl40
PHP40
Python40
R
初級10
中級10
上級10
エキスパート5
マスター5
tidyverse_model.r
s4_method.r
shiny_app.r
parallel.r
rlang_quo.r
Ruby40
Rust40
Shell40
Swift40
TypeScript40
s4_method.r
Click to focus
1
2
3
4
5
6
7
8
9
10
11
12
13
setClass("Data",
 slots = c(x = "numeric", y = "numeric")
)
setMethod("plot", "Data",
 function(x, ...) {
   plot(x@x, x@y, ...)
 }
)
setMethod("+", c("Data", "Data"),
 function(e1, e2) {
   new("Data", x = e1@x + e2@x, y = e1@y + e2@y)
 }
)
0WPM0%0:000/241(0%)|Ln 1, Col 1
UTF-8R

関連する練習問題