0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

JupyterLab 自分用メモ

Last updated at Posted at 2020-05-01

Jupyter Notebookの先頭

import numpy as np
import pandas as pd
import matplotlib.pyplot as plt
import seaborn as sns
import japanize_matplotlib
import scipy.stats as st

def plt_legend_out(frameon=True):
    plt.legend(bbox_to_anchor=(1.05, 1), loc='upper left', borderaxespad=0, frameon=frameon)
plt.rcParams['font.size'] = 15
from IPython.display import HTML

HTML('''
<script>  
code_show=true; 
function code_toggle() {
  if (code_show){
    $(\'div.input\').hide();
  } else {
    $(\'div.input\').show();
  }
  code_show = !code_show
}  
$( document ).ready(code_toggle);
</script>
<form action="javascript:code_toggle()">
    <input type="submit" value="Toggle code">
</form>
''')

マル秘マーク

<font size="5"><div align="right"><span style="border: 1px solid red; color: red">秘</span></div></font>

image.png

LaTeX

$
f(x)=
\left(
\begin{array}{ccc}
  f_1(x) \\
  f_2(x)
\end{array}
\right)=
\left(
\begin{array}{ccc}
  x^3-2y \\
  x^2+y^2-1
\end{array}
\right)=
\left(
\begin{array}{ccc}
  0 \\
  0
\end{array}
\right)
$

Python 自作関数

有効桁数を3桁に

def sig_dig(x):
    return np.float('%s' % np.float('%.3g' % x))

ggplot

文字の大きさのデフォルト値

theme_set(theme_bw(base_size = 20))

グラフの大きさ

options(repr.plot.width=7, repr.plot.height=4)
0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?