Data visualization in Python (Coursera course)

イメージ
さて、pythonの方も最低1回/週ペースでは勉強していきたい。いや。行かねば。というこtで、 Courseraのコースを再検索。Python関連で興味の持てるコースとしては、 カリフォルニア大学が開いている、 The Raspberry Pi Platform and Python Programming for the Raspberry Pi というコースと、 IBMが主催している、 というコースがあった。で、どちらにしようかなーと思ったが、仕事でも役にたちそうで仕事で暇なときは仕事をしつつ勉強もできそうな Data Visualization with Pythonを受講することにしてみた。 Introduction のビデオを見てみたが、 Matplotlib, seaborn, folim といったライブラリを使って Dataの見えるかを行っていくようだ。 Week1の1st videも少し見てみた。知らなかったが、 Alberta大学の研究所からスピンアウトして設立したDARKHORSE analyticsという会社がデータの見えるかに関して良い仕事をしたらしい。 言いたいことをすぐにわかるようにするグラフを使おうということで、ごたごた飾り付けた3D Pie chartよりは、シンプルに言いたい部分だけ強調した bar chartが良いと。 ふむふむ。 なるほどね。。。。 もっと例が見たかったら,  http:///www.darkhorseanalytics.com/ へ行けと。。 いや。いいね。すごいね。見せ方が。 http://grades.dha.io/ https://www.darkhorseanalytics.com/portfolio/breathing-city こんな例もとても分かりやすい。分かりやすさがすごいね。 https://www.darkhorseanalytics.com/portfolio/2016/1/7/data-looks-better-naked-clear-off-the-table

Angular4 学習 (Udemy) -1. Install

Angular4 を Udemy で学んでみる。

環境は勉強用に、vagrantでcentos 7.3環境を作成。今の環境は汚したくないので。

d:\vagrant
mkdir angular4-centos
cd angu*
copy ..\centos\Vagrantfile .    ←開発環境用のVagrantfileはここに置いてある。
vagrant up

で、centos7.3 環境をさくっと新規に立ち上げる。便利な世の中になったもんだ。

vagrantユーザでログイン。一応パスワードは変えておく。 

centos7 へのインストールは、公式サイトの手順に従う。
https://nodejs.org/en/download/package-manager/#enterprise-linux-and-fedora

LTS(Long Term Support)バージョンを入れることにする。
curl --silent --location https://rpm.nodesource.com/setup_6.x | sudo bash -

sudo yum -y install nodejs
一応公式サイトにある Optional: な手順も実行
sudo yum install gcc-c++ make

で、いよいよ angular4.

angular cli のサイト https://cli.angular.io/ の通り、

$ npm install -g @angular/cli
でインストール

あれ? linux x64 はサポートされてない? エラーになった。

npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.1.2: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm ERR! Linux 3.10.0-229.el7.x86_64
npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "install" "-g" "@angular/cli"
npm ERR! node v6.11.4
npm ERR! npm  v3.10.10
npm ERR! path /usr/lib/node_modules
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall access

npm ERR! Error: EACCES: permission denied, access '/usr/lib/node_modules'
npm ERR!     at Error (native)
npm ERR!  { Error: EACCES: permission denied, access '/usr/lib/node_modules'
npm ERR!     at Error (native)
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   syscall: 'access',
npm ERR!   path: '/usr/lib/node_modules' }
npm ERR!
npm ERR! Please try running this command again as root/Administrator.

npm ERR! Please include the following file with any support request:
npm ERR!     /home/vagrant/npm-debug.log

あー。 root ならいけるのか? スーパユーザになってやり直す。

# npm install -g @angular/cli

npm install -g @angular/cli
/usr/bin/ng -> /usr/lib/node_modules/@angular/cli/bin/ng

> node-sass@4.5.3 install /usr/lib/node_modules/@angular/cli/node_modules/node-sass
> node scripts/install.js

Downloading binary from https://github.com/sass/node-sass/releases/download/v4.5.3/linux-x64-48_binding.node
Download complete  ] - :
Binary saved to /usr/lib/node_modules/@angular/cli/node_modules/node-sass/vendor/linux-x64-48/binding.node
Caching binary to /root/.npm/node-sass/4.5.3/linux-x64-48_binding.node
Failed to cache binary: { Error: EACCES: permission denied, open '/root/.npm/node-sass/4.5.3/linux-x64-48_binding.node'
    at Error (native)
  errno: -13,
  code: 'EACCES',
  syscall: 'open',
  path: '/root/.npm/node-sass/4.5.3/linux-x64-48_binding.node' }

> uglifyjs-webpack-plugin@0.4.6 postinstall /usr/lib/node_modules/@angular/cli/node_modules/uglifyjs-webpack-plugin
> node lib/post_install.js


なんか気になるエラー(Failed to cache binary: ) はあるが、インストールはされたかな?
・一応 node-sass がエラーになっているのも気持ち悪いので、個別に node-sass をインストールしておく。

# npm install -g node-sass

v4.5.3/linux-x64-48_binding.nodeがダウンロードされてインストールされたようなので良しとして先に進む。

一応、一般ユーザにもどって、$ ng version としてみる。

$ ng version
    _                      _                 ____ _     ___
   / \   _ __   __ _ _   _| | __ _ _ __     / ___| |   |_ _|
  / △ \ | '_ \ / _` | | | | |/ _` | '__|   | |   | |    | |
 / ___ \| | | | (_| | |_| | | (_| | |      | |___| |___ | |
/_/   \_\_| |_|\__, |\__,_|_|\__,_|_|       \____|_____|___|
               |___/
@angular/cli: 1.4.9
node: 6.11.4
os: linux x64

とりま OK のよう。



コメント

このブログの人気の投稿

Python_programming (Coursera)

Data visualization in Python (Coursera course)

やりたいこと