やりたいこと ggplot2で日本語を利用できるようにする 前提 サーバーでRを実行している レポートhtmlを作成している レポートのグラフ中に日本語が含まれる ggplot2ではデフォルトの設定では日本語はサポートされていないので、フォントの指定が必要。 でも、そもそも、サーバーにフォントが入っていないこともあるので、サーバーにフォントのインストールから始める やったこと 作業の流れ インストール済みの日本語フォントの確認 任意の日本語フォントのインストール ggplot2で設定する 1 日本語フォントの確認 fc-list|less でインストール済みのフォント一覧が確認可能。 IPA系統がなければ、日本語フォントなしと考えてもよさそう。 2 日本語フォントのインストール IPAフォントのセットをインストールする。 IPAフォントをダウンロードできるページ wget ファイルダウンロ