mysql -u root -p //로그인
create database rprogramming;
use rprogramming;
create table rtest(name varchar (20),
-> score integer);
insert into rtest2 values("a",50);
insert into rtest2 values("b",90);
dbConnect(MySQL(), user = "root" , password = "1234", host = "127.0.0.1", dbname="rprogramming")
install.packages("RMySQL")
library(RMySQL)
con = dbConnect(MySQL(), user = "root" , password = "1234",
host = "127.0.0.1", dbname="rprogramming")
dbListTables(con)
df = dbGetQuery( con, "select * from rtest2" )
str(df)
class(df)
'딥러닝 모델 설계 > R STUDIO' 카테고리의 다른 글
라이브러리, ggplot x축 분할, Flip, Join, excel, discrete, fill, position (0) | 2019.05.20 |
---|---|
library, wordcloud, str_split, paste, nchar, str_replace, ggplot , wefare (0) | 2019.05.17 |
rbind, apply, sample,split, subset, names, merge (0) | 2019.05.16 |
head, view , summary, dim. summarize, rename, mutate, group_by (0) | 2019.05.15 |
패키지 추가, 조건 결합, 범주형, qplot, excel, filter, select, arrange (0) | 2019.05.13 |