Suche senden
Hochladen
RHadoop の紹介
•
Als KEY, PDF herunterladen
•
9 gefällt mir
•
3,200 views
Hidekazu Tanaka
Folgen
Technologie
Sport
Melden
Teilen
Melden
Teilen
1 von 22
Jetzt herunterladen
Empfohlen
R meets Hadoop
R meets Hadoop
Hidekazu Tanaka
imager package in R and examples..
imager package in R and examples..
Dr. Volkan OBAN
Advanced Data Visualization in R- Somes Examples.
Advanced Data Visualization in R- Somes Examples.
Dr. Volkan OBAN
Basic Calculus in R.
Basic Calculus in R.
Dr. Volkan OBAN
R + Hadoop = Big Data Analytics. How Revolution Analytics' RHadoop Project Al...
R + Hadoop = Big Data Analytics. How Revolution Analytics' RHadoop Project Al...
Revolution Analytics
Some R Examples[R table and Graphics] -Advanced Data Visualization in R (Some...
Some R Examples[R table and Graphics] -Advanced Data Visualization in R (Some...
Dr. Volkan OBAN
Mosaic plot in R.
Mosaic plot in R.
Dr. Volkan OBAN
A Shiny Example-- R
A Shiny Example-- R
Dr. Volkan OBAN
Empfohlen
R meets Hadoop
R meets Hadoop
Hidekazu Tanaka
imager package in R and examples..
imager package in R and examples..
Dr. Volkan OBAN
Advanced Data Visualization in R- Somes Examples.
Advanced Data Visualization in R- Somes Examples.
Dr. Volkan OBAN
Basic Calculus in R.
Basic Calculus in R.
Dr. Volkan OBAN
R + Hadoop = Big Data Analytics. How Revolution Analytics' RHadoop Project Al...
R + Hadoop = Big Data Analytics. How Revolution Analytics' RHadoop Project Al...
Revolution Analytics
Some R Examples[R table and Graphics] -Advanced Data Visualization in R (Some...
Some R Examples[R table and Graphics] -Advanced Data Visualization in R (Some...
Dr. Volkan OBAN
Mosaic plot in R.
Mosaic plot in R.
Dr. Volkan OBAN
A Shiny Example-- R
A Shiny Example-- R
Dr. Volkan OBAN
ggtimeseries-->ggplot2 extensions
ggtimeseries-->ggplot2 extensions
Dr. Volkan OBAN
CLIM Undergraduate Workshop: Tutorial on R Software - Huang Huang, Oct 23, 2017
CLIM Undergraduate Workshop: Tutorial on R Software - Huang Huang, Oct 23, 2017
The Statistical and Applied Mathematical Sciences Institute
C++ TUTORIAL 6
C++ TUTORIAL 6
Farhan Ab Rahman
ECMAScript 6 major changes
ECMAScript 6 major changes
hayato
Python hmm
Python hmm
立民 林
C++ TUTORIAL 7
C++ TUTORIAL 7
Farhan Ab Rahman
Om (Cont.)
Om (Cont.)
Taku Fukushima
Plot3D Package and Example in R.-Data visualizat,on
Plot3D Package and Example in R.-Data visualizat,on
Dr. Volkan OBAN
Effector: we need to go deeper
Effector: we need to go deeper
Victor Didenko
C++ TUTORIAL 10
C++ TUTORIAL 10
Farhan Ab Rahman
Angular Refactoring in Real World
Angular Refactoring in Real World
bitbank, Inc. Tokyo, Japan
Hacking the Internet of Things for Fun & Profit
Hacking the Internet of Things for Fun & Profit
Ruben van Vreeland
dplyr
dplyr
Romain Francois
Camping
Camping
Gregor Schmidt
C++ TUTORIAL 3
C++ TUTORIAL 3
Farhan Ab Rahman
C++ TUTORIAL 9
C++ TUTORIAL 9
Farhan Ab Rahman
Vcs9
Vcs9
Malikireddy Bramhananda Reddy
Clojure to Slang
Clojure to Slang
Magne Gåsland
Metaprogramming
Metaprogramming
Dmitri Nesteruk
Go: It's Not Just For Google
Go: It's Not Just For Google
Eleanor McHugh
A world without islam-graham e. fuller
A world without islam-graham e. fuller
MD. Monzurul Karim Shanchay
Povezovanje kemijske panoge in delo z mladimi, KOCKE, Ziga Lampe, Drzava za g...
Povezovanje kemijske panoge in delo z mladimi, KOCKE, Ziga Lampe, Drzava za g...
Aleš Vidmar
Weitere ähnliche Inhalte
Was ist angesagt?
ggtimeseries-->ggplot2 extensions
ggtimeseries-->ggplot2 extensions
Dr. Volkan OBAN
CLIM Undergraduate Workshop: Tutorial on R Software - Huang Huang, Oct 23, 2017
CLIM Undergraduate Workshop: Tutorial on R Software - Huang Huang, Oct 23, 2017
The Statistical and Applied Mathematical Sciences Institute
C++ TUTORIAL 6
C++ TUTORIAL 6
Farhan Ab Rahman
ECMAScript 6 major changes
ECMAScript 6 major changes
hayato
Python hmm
Python hmm
立民 林
C++ TUTORIAL 7
C++ TUTORIAL 7
Farhan Ab Rahman
Om (Cont.)
Om (Cont.)
Taku Fukushima
Plot3D Package and Example in R.-Data visualizat,on
Plot3D Package and Example in R.-Data visualizat,on
Dr. Volkan OBAN
Effector: we need to go deeper
Effector: we need to go deeper
Victor Didenko
C++ TUTORIAL 10
C++ TUTORIAL 10
Farhan Ab Rahman
Angular Refactoring in Real World
Angular Refactoring in Real World
bitbank, Inc. Tokyo, Japan
Hacking the Internet of Things for Fun & Profit
Hacking the Internet of Things for Fun & Profit
Ruben van Vreeland
dplyr
dplyr
Romain Francois
Camping
Camping
Gregor Schmidt
C++ TUTORIAL 3
C++ TUTORIAL 3
Farhan Ab Rahman
C++ TUTORIAL 9
C++ TUTORIAL 9
Farhan Ab Rahman
Vcs9
Vcs9
Malikireddy Bramhananda Reddy
Clojure to Slang
Clojure to Slang
Magne Gåsland
Metaprogramming
Metaprogramming
Dmitri Nesteruk
Go: It's Not Just For Google
Go: It's Not Just For Google
Eleanor McHugh
Was ist angesagt?
(20)
ggtimeseries-->ggplot2 extensions
ggtimeseries-->ggplot2 extensions
CLIM Undergraduate Workshop: Tutorial on R Software - Huang Huang, Oct 23, 2017
CLIM Undergraduate Workshop: Tutorial on R Software - Huang Huang, Oct 23, 2017
C++ TUTORIAL 6
C++ TUTORIAL 6
ECMAScript 6 major changes
ECMAScript 6 major changes
Python hmm
Python hmm
C++ TUTORIAL 7
C++ TUTORIAL 7
Om (Cont.)
Om (Cont.)
Plot3D Package and Example in R.-Data visualizat,on
Plot3D Package and Example in R.-Data visualizat,on
Effector: we need to go deeper
Effector: we need to go deeper
C++ TUTORIAL 10
C++ TUTORIAL 10
Angular Refactoring in Real World
Angular Refactoring in Real World
Hacking the Internet of Things for Fun & Profit
Hacking the Internet of Things for Fun & Profit
dplyr
dplyr
Camping
Camping
C++ TUTORIAL 3
C++ TUTORIAL 3
C++ TUTORIAL 9
C++ TUTORIAL 9
Vcs9
Vcs9
Clojure to Slang
Clojure to Slang
Metaprogramming
Metaprogramming
Go: It's Not Just For Google
Go: It's Not Just For Google
Andere mochten auch
A world without islam-graham e. fuller
A world without islam-graham e. fuller
MD. Monzurul Karim Shanchay
Povezovanje kemijske panoge in delo z mladimi, KOCKE, Ziga Lampe, Drzava za g...
Povezovanje kemijske panoge in delo z mladimi, KOCKE, Ziga Lampe, Drzava za g...
Aleš Vidmar
Sig App4
Sig App4
Kenji Ono
Social Media Success in International Student Recruitment
Social Media Success in International Student Recruitment
Marty Bennett
SSBs Erling Holmøy_Norge eldes: Langsiktig økonomisk bærekraft 28.01.14
SSBs Erling Holmøy_Norge eldes: Langsiktig økonomisk bærekraft 28.01.14
Statistisk sentralbyrå
MvSM: 7) Co tam dávat - tvorba obsahu pro sociální média
MvSM: 7) Co tam dávat - tvorba obsahu pro sociální média
Matez Jindra
Funcionario, ¿qué le pides tú a la administración electrónica?
Funcionario, ¿qué le pides tú a la administración electrónica?
Alberto Ortiz de Zarate
Márkaépítés a fogyasztói kontroll korában 2.0
Márkaépítés a fogyasztói kontroll korában 2.0
Isobar Budapest
Lucy redes sociales myspace
Lucy redes sociales myspace
Lucy Stella Gacha Baquero
Advanced php
Advanced php
hamfu
Buyer Persona - Key to B2B online marketing success
Buyer Persona - Key to B2B online marketing success
ShimonBen
Design persuasivo: alcuni esempi
Design persuasivo: alcuni esempi
Alberto Mucignat
Balonmán touro
Balonmán touro
davidares1
Tesla Croatia
Tesla Croatia
Teslacroatia
Enquête Doctipharma : Les français et la vente de médicaments sur internet
Enquête Doctipharma : Les français et la vente de médicaments sur internet
Doctipharma
Amnesty International
Amnesty International
socialsubjects
Baby Love -Wildlife
Baby Love -Wildlife
Makala D.
Aseemearth
Aseemearth
Sumit Singh
Subsidio i.1 demanda actual
Subsidio i.1 demanda actual
Upaep Online
Valsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēma
Valsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēma
Pārresoru kordinācijas centrs (PKC)
Andere mochten auch
(20)
A world without islam-graham e. fuller
A world without islam-graham e. fuller
Povezovanje kemijske panoge in delo z mladimi, KOCKE, Ziga Lampe, Drzava za g...
Povezovanje kemijske panoge in delo z mladimi, KOCKE, Ziga Lampe, Drzava za g...
Sig App4
Sig App4
Social Media Success in International Student Recruitment
Social Media Success in International Student Recruitment
SSBs Erling Holmøy_Norge eldes: Langsiktig økonomisk bærekraft 28.01.14
SSBs Erling Holmøy_Norge eldes: Langsiktig økonomisk bærekraft 28.01.14
MvSM: 7) Co tam dávat - tvorba obsahu pro sociální média
MvSM: 7) Co tam dávat - tvorba obsahu pro sociální média
Funcionario, ¿qué le pides tú a la administración electrónica?
Funcionario, ¿qué le pides tú a la administración electrónica?
Márkaépítés a fogyasztói kontroll korában 2.0
Márkaépítés a fogyasztói kontroll korában 2.0
Lucy redes sociales myspace
Lucy redes sociales myspace
Advanced php
Advanced php
Buyer Persona - Key to B2B online marketing success
Buyer Persona - Key to B2B online marketing success
Design persuasivo: alcuni esempi
Design persuasivo: alcuni esempi
Balonmán touro
Balonmán touro
Tesla Croatia
Tesla Croatia
Enquête Doctipharma : Les français et la vente de médicaments sur internet
Enquête Doctipharma : Les français et la vente de médicaments sur internet
Amnesty International
Amnesty International
Baby Love -Wildlife
Baby Love -Wildlife
Aseemearth
Aseemearth
Subsidio i.1 demanda actual
Subsidio i.1 demanda actual
Valsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēma
Valsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēma
Ähnlich wie RHadoop の紹介
RHadoop, R meets Hadoop
RHadoop, R meets Hadoop
Revolution Analytics
CLUSTERGRAM
CLUSTERGRAM
Dr. Volkan OBAN
Jan 2012 HUG: RHadoop
Jan 2012 HUG: RHadoop
Yahoo Developer Network
Monadologie
Monadologie
league
Advanced Data Visualization Examples with R-Part II
Advanced Data Visualization Examples with R-Part II
Dr. Volkan OBAN
Javascript
Javascript
Vlad Ifrim
Python 101 language features and functional programming
Python 101 language features and functional programming
Lukasz Dynowski
Haskellで学ぶ関数型言語
Haskellで学ぶ関数型言語
ikdysfm
Super Advanced Python –act1
Super Advanced Python –act1
Ke Wei Louis
Scala by Luc Duponcheel
Scala by Luc Duponcheel
Stephan Janssen
Map, Reduce and Filter in Swift
Map, Reduce and Filter in Swift
Aleksandras Smirnovas
Algorithm Design and Analysis - Practical File
Algorithm Design and Analysis - Practical File
KushagraChadha1
Script jantung copy
Script jantung copy
Nurwahidah Abidin
Map/reduce, geospatial indexing, and other cool features (Kristina Chodorow)
Map/reduce, geospatial indexing, and other cool features (Kristina Chodorow)
MongoSF
Rainer Grimm, “Functional Programming in C++11”
Rainer Grimm, “Functional Programming in C++11”
Platonov Sergey
intro-to-metaprogramming-in-r.pdf
intro-to-metaprogramming-in-r.pdf
K. Matthew Dupree
TI1220 Lecture 6: First-class Functions
TI1220 Lecture 6: First-class Functions
Eelco Visser
Celery - A Distributed Task Queue
Celery - A Distributed Task Queue
Duy Do
Optimization and Mathematical Programming in R and ROI - R Optimization Infra...
Optimization and Mathematical Programming in R and ROI - R Optimization Infra...
Dr. Volkan OBAN
BUilt in Functions and Simple programs in R.pdf
BUilt in Functions and Simple programs in R.pdf
karthikaparthasarath
Ähnlich wie RHadoop の紹介
(20)
RHadoop, R meets Hadoop
RHadoop, R meets Hadoop
CLUSTERGRAM
CLUSTERGRAM
Jan 2012 HUG: RHadoop
Jan 2012 HUG: RHadoop
Monadologie
Monadologie
Advanced Data Visualization Examples with R-Part II
Advanced Data Visualization Examples with R-Part II
Javascript
Javascript
Python 101 language features and functional programming
Python 101 language features and functional programming
Haskellで学ぶ関数型言語
Haskellで学ぶ関数型言語
Super Advanced Python –act1
Super Advanced Python –act1
Scala by Luc Duponcheel
Scala by Luc Duponcheel
Map, Reduce and Filter in Swift
Map, Reduce and Filter in Swift
Algorithm Design and Analysis - Practical File
Algorithm Design and Analysis - Practical File
Script jantung copy
Script jantung copy
Map/reduce, geospatial indexing, and other cool features (Kristina Chodorow)
Map/reduce, geospatial indexing, and other cool features (Kristina Chodorow)
Rainer Grimm, “Functional Programming in C++11”
Rainer Grimm, “Functional Programming in C++11”
intro-to-metaprogramming-in-r.pdf
intro-to-metaprogramming-in-r.pdf
TI1220 Lecture 6: First-class Functions
TI1220 Lecture 6: First-class Functions
Celery - A Distributed Task Queue
Celery - A Distributed Task Queue
Optimization and Mathematical Programming in R and ROI - R Optimization Infra...
Optimization and Mathematical Programming in R and ROI - R Optimization Infra...
BUilt in Functions and Simple programs in R.pdf
BUilt in Functions and Simple programs in R.pdf
Mehr von Hidekazu Tanaka
ggplot2 に入門してみた
ggplot2 に入門してみた
Hidekazu Tanaka
データベースのお話
データベースのお話
Hidekazu Tanaka
フォントのお話
フォントのお話
Hidekazu Tanaka
フォントのお話
フォントのお話
Hidekazu Tanaka
バギングで構築された各決定木
バギングで構築された各決定木
Hidekazu Tanaka
アンサンブル学習
アンサンブル学習
Hidekazu Tanaka
Rの紹介
Rの紹介
Hidekazu Tanaka
Rで解く最適化問題 線型計画問題編
Rで解く最適化問題 線型計画問題編
Hidekazu Tanaka
RでMapreduce
RでMapreduce
Hidekazu Tanaka
Rによるやさしい統計学 第16章 : 因子分析
Rによるやさしい統計学 第16章 : 因子分析
Hidekazu Tanaka
Mehr von Hidekazu Tanaka
(10)
ggplot2 に入門してみた
ggplot2 に入門してみた
データベースのお話
データベースのお話
フォントのお話
フォントのお話
フォントのお話
フォントのお話
バギングで構築された各決定木
バギングで構築された各決定木
アンサンブル学習
アンサンブル学習
Rの紹介
Rの紹介
Rで解く最適化問題 線型計画問題編
Rで解く最適化問題 線型計画問題編
RでMapreduce
RでMapreduce
Rによるやさしい統計学 第16章 : 因子分析
Rによるやさしい統計学 第16章 : 因子分析
Kürzlich hochgeladen
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
Puma Security, LLC
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
ThousandEyes
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
Radu Cotescu
How to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
naman860154
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
Neo4j
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
HampshireHUG
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
Maria Levchenko
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
Ridwan Fadjar
Key Features Of Token Development (1).pptx
Key Features Of Token Development (1).pptx
LBM Solutions
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
Paola De la Torre
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
Gabriella Davis
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
AndikSusilo4
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
Malak Abu Hammad
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
Mark Billinghurst
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
Delhi Call girls
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
Allon Mureinik
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
2toLead Limited
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
shyamraj55
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
Delhi Call girls
Kürzlich hochgeladen
(20)
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
How to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
SIEMENS: RAPUNZEL – A Tale About Knowledge Graph
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
Key Features Of Token Development (1).pptx
Key Features Of Token Development (1).pptx
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
Azure Monitor & Application Insight to monitor Infrastructure & Application
Azure Monitor & Application Insight to monitor Infrastructure & Application
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Neo4j - How KGs are shaping the future of Generative AI at AWS Summit London ...
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
RHadoop の紹介
1.
1
2.
2
3.
• •
• • 3
4.
• • • •
4
5.
• •
• • • 5
6.
6
7.
• •
• • • • • 7
8.
R CMD INSTALL
'package filename' 8
9.
9
10.
> small.ints =
to.dfs(1:10) > out = mapreduce(input = small.ints, map = function(k,v) keyval(k, k^2)) > res = from.dfs(out) > colres <- do.call('rbind', lapply(res,"[[",2)) > t(colres) [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [1,] 1 4 9 16 25 36 49 64 81 100 > groups = to.dfs(rbinom(32, n = 50, prob = 0.4)) > out = mapreduce(input = groups, reduce = function(k,vv) keyval(k, length(vv))) > res = from.dfs(out) > colres <- do.call('rbind', lapply(res,"[[",2)) > t(colres) [,1] [,2] [,3] [,4] [,5] [,6] [,7] [,8] [,9] [,10] [,11] [,12] [1,] 2 7 3 1 1 12 2 8 8 1 4 1 10
11.
> wordcount
= function(input, output = NULL, pattern = " ") { + mapreduce(input = input, + output = output, + textinputformat = rawtextinputformat, + map = function(k ,v) { + lapply(strsplit(x = v, split = pattern) [[1]], + function(w) keyval(w,1)) + }, + reduce = function(k, vv) { + keyval(k, sum(unlist(vv))) + }, + combine = T) + } > out <- wordcount(input="/user/hidekazu/the_social_network.txt") > results <- from.dfs(out) > results <- data.frame(word=unlist(lapply(results,"[[",1)), count=unlist(lapply(results,"[[",2))) > results <- (results[order(results$count, decreasing=TRUE), ]) > head(results) word count 6313 the 1101 2381 a 700 11 26 and 637
12.
12
13.
kmeans.iter =
function(points, distfun, ncenters = length(centers), centers = NULL) { from.dfs( mapreduce(input = points, map = if (is.null(centers)) { function(k,v)keyval(sample(1:ncenters,1),v) } else { function(k,v) { distances = lapply(centers, function(c) distfun(c,v)) keyval(centers[[which.min(distances)]],v) } }, reduce = function(k,vv) keyval(NULL, apply(do.call(rbind, vv), 2, mean))) ) } 13
14.
kmeans =
function(points, ncenters, iterations = 10, distfun = function(a,b) norm(as.matrix(a-b), type = 'F')) { newCenters = kmeans.iter(points, distfun = distfun, ncenters = ncenters) for(i in 1:iterations) { newCenters = lapply(values(newCenters), unlist) newCenters = kmeans.iter(points, distfun, centers=newCenters) } newCenters } clustdata = lapply(1:10000, function(i) keyval(i, c(rnorm(1, mean = i%%3, sd = 0.01), rnorm(1, mean = i%%4, sd = 0.01)))) to.dfs(clustdata, "/tmp/clustdata") kmeans ("/tmp/clustdata", 12) 14
15.
15
16.
15
17.
16
18.
> model <-
kmeans(iris[, 1:4], 3, nstart=10) > modelfilename <- "my_smart_unique_name" > modelfile <- hdfs.file(modelfilename, "w") > hdfs.write(model, modelfile) [1] TRUE > hdfs.close(modelfile) [1] TRUE > modelfile = hdfs.file(modelfilename, "r") > m <- hdfs.read(modelfile) Warning message: In function (h) : Closed unused DFS stream: my_smart_unique_name > model <- unserialize(m) > hdfs.close(modelfile) [1] TRUE > model 17
19.
18
20.
•
• 19
21.
•
20
22.
•
• • • • 21
Hinweis der Redaktion
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
Jetzt herunterladen