from IPython.display import HTML
HTML('''<script>
code_show=true;
function code_toggle() {
if (code_show){
$('div.input').hide();
$('div.output_stderr').hide();
} else {
$('div.input').show();
$('div.output_stderr').show();
}
code_show = !code_show
}
$( document ).ready(code_toggle);
</script>
<form action='javascript:code_toggle()'><input STYLE='color: #4286f4'
type='submit' value='Click here to toggle on/off the raw code.'></form>''')
import matplotlib.pylab as plt
import numpy as np
x = np.linspace(-np.pi, np.pi, 201)
plt.plot(x, np.sin(x))
plt.xlabel('Angle [rad]')
plt.ylabel('sin(x)')
plt.axis('tight')
plt.show()
from IPython.core.display import display, HTML
display(HTML('<h1 style= "text-align:center"> Hello world! </h1>'))
Ez itt ki van emelve, mert nagyon fontos.
C:\Users\furu> echo "Hello world!"
HTML("""<head>
<title>CSS Layout</title>
<link rel="stylesheet" type="text/css" href="more_css.css">
</head>
""")