Replace toy_document_orgmode_R_fr.org

parent 68146b99
#+TITLE: À propos du calcul de $\pi$
#+LANGUAGE: fr
# #+PROPERTY: header-args :eval never-export
#+HTML_HEAD: <link rel="stylesheet" type="text/css" href="http://www.pirilampo.org/styles/readtheorg/css/htmlize.css"/>
#+HTML_HEAD: <link rel="stylesheet" type="text/css" href="http://www.pirilampo.org/styles/readtheorg/css/readtheorg.css"/>
......@@ -50,19 +49,6 @@ se base sur le fait que si $X\sim U(0,1)$ et $Y\sim U(0,1)$ alors $P[X^2+Y^2\leq
Monte Carlo sur Wikipedia]]). Le code suivant illustre ce fait :
#+begin_src R :results output graphics :file figure_pi_mc1.png :exports both :width 600 :height 400 :session *R*
# is mooc teachers' setting to get to the output
set.seed(42)
N = 1000
df = data.frame(X = runif(N), Y = runif(N))
df$Accept = (df$X**2 + df$Y**2 <=1)
library(ggplot2)
ggplot(df, aes(x=X,y=Y,color=Accept)) + geom_point(alpha=.2) + coord_fixed() + theme_bw()
#+end_src
#+RESULTS:
#+begin_src R :file figure_pi_mc1.png :results output file :exports both :width 600 :height 400 :session *R*
# is my setting to get to the output
set.seed(42)
N = 1000
df = data.frame(X = runif(N), Y = runif(N))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment