Started working on pointprocesses

This commit is contained in:
2015-10-25 22:22:54 +01:00
parent d9252e9cbf
commit 857373c125
24 changed files with 892 additions and 688 deletions

View File

@@ -1,22 +1,29 @@
BASENAME=statistics
PYFILES=$(wildcard *.py)
PYPDFFILES=$(PYFILES:.py=.pdf)
pdf : $(BASENAME)-chapter.pdf $(PYPDFFILES)
all : pdf
$(BASENAME)-chapter.pdf : $(BASENAME)-chapter.tex $(BASENAME).tex
# script:
pdf : $(BASENAME)-chapter.pdf
$(BASENAME)-chapter.pdf : $(BASENAME)-chapter.tex $(BASENAME).tex $(PYPDFFILES)
pdflatex -interaction=scrollmode $< | tee /dev/stderr | fgrep -q "Rerun to get cross-references right" && pdflatex -interaction=scrollmode $< || true
$(PYPDFFILES) : %.pdf : %.py
python $<
clean :
rm -f *~ $(BASENAME)-chapter.aux $(BASENAME)-chapter.log $(BASENAME)-chapter.out $(BASENAME).aux $(BASENAME).log
rm -f *~
rm -f $(BASENAME).aux $(BASENAME).log
rm -f $(BASENAME)-chapter.aux $(BASENAME)-chapter.log $(BASENAME)-chapter.out
rm -f $(PYPDFFILES) $(GPTTEXFILES)
cleanall : clean
rm -f $(BASENAME)-chapter.pdf
watch :
watchpdf :
while true; do ! make -q pdf && make pdf; sleep 0.5; done

View File

@@ -43,5 +43,5 @@ ax.annotate('maximum',
ax.boxplot( x, whis=100.0 )
plt.tight_layout()
plt.savefig('boxwhisker.pdf')
plt.show()
#plt.show()

View File

@@ -5,7 +5,6 @@ plt.xkcd()
fig = plt.figure( figsize=(6,5) )
n = 200
for k, r in enumerate( [ 1.0, 0.6, 0.0, -0.9 ] ) :
print r
x = np.random.randn( n )
y = r*x + np.sqrt(1.0-r*r)*np.random.randn( n )
ax = fig.add_subplot( 2, 2, k+1 )
@@ -30,5 +29,4 @@ for k, r in enumerate( [ 1.0, 0.6, 0.0, -0.9 ] ) :
plt.tight_layout()
plt.savefig('correlation.pdf')
plt.show()
#plt.show()

View File

@@ -28,5 +28,4 @@ ax.set_ylabel( 'Probability' )
ax.hist([x2, x1], bins, normed=True, color=['#FFCC00', '#FFFF66' ])
plt.tight_layout()
fig.savefig( 'diehistograms.pdf' )
plt.show()
#plt.show()

View File

@@ -29,5 +29,4 @@ ax.plot(x,g, 'b', lw=4)
ax.plot([0.0, 0.0], [0.0, 0.45], 'k', lw=2 )
plt.tight_layout()
fig.savefig( 'median.pdf' )
plt.show()
#plt.show()

View File

@@ -39,4 +39,4 @@ ax.scatter( x, z )
plt.tight_layout()
plt.savefig('nonlincorrelation.pdf')
plt.show()
#plt.show()

View File

@@ -35,5 +35,5 @@ ax.hist(r, 20, normed=True, color='#FFCC00')
plt.tight_layout()
fig.savefig( 'pdfhistogram.pdf' )
plt.show()
#plt.show()

View File

@@ -32,5 +32,4 @@ ax.fill_between( x[(x>x1)&(x<x2)], 0.0, g[(x>x1)&(x<x2)], color='#cc0000' )
ax.plot(x,g, 'b', lw=4)
plt.tight_layout()
fig.savefig( 'pdfprobabilities.pdf' )
plt.show()
#plt.show()

View File

@@ -46,5 +46,4 @@ ax.plot([q[0], q[0]], [0.0, 0.4], 'k', lw=2 )
ax.plot([q[2], q[2]], [0.0, 0.4], 'k', lw=2 )
plt.tight_layout()
fig.savefig( 'quartile.pdf' )
plt.show()
#plt.show()