diff --git a/triangle_gcm_initial_analysis.m b/triangle_gcm_initial_analysis.m index 136c6532adecf180add97ba1161906cc5381ec2e..fa9e57f17fa4cea5907a5e6d4e6272bbafba5e69 100644 --- a/triangle_gcm_initial_analysis.m +++ b/triangle_gcm_initial_analysis.m @@ -44,8 +44,8 @@ getTotalStats[runs_]:=Transpose[Map[getAverage,runs]]; totalStats=Map[getTotalStats,gdata,{2}]; -(* Yellow: GCM1 (take new highest everytime *) -(* Blue: GCM2 (finish highest first, more similar to EG) *) +(* Yellow: CCMu (take new highest everytime *) +(* Blue: CCMb (finish highest first, more similar to EG) *) histogramsTotal=Map[Histogram[#,{0.05},PlotRange->{{-0.5,2},Automatic},ImageSize->300,AxesOrigin->{0,0}]&,totalStats,{2}]; @@ -57,10 +57,12 @@ TableForm[histogramsTotal,TableHeadings->{taulabels,nlabels}] makeHistogram[datasets_,n_,tau_]:=Histogram[datasets,{0.05},"Probability", -PlotRange->{{0,1},{0,0.5}}, +PlotRange->{{0,1.3},{0,0.5}}, ImageSize->300,AxesOrigin->{0,0}, +AspectRatio->3/5, Frame->True, FrameLabel->{"fraction of average #triangles at CCM start","frequency"}, +ChartLegends->Placed[{"CCMu avg = "<>ToString[NumberForm[N[Mean[datasets[[1]]]],2]],"CCMb avg = "<>ToString[NumberForm[N[Mean[datasets[[2]]]],2]]},Center], (*LabelingFunction->(Placed[NumberForm[#,{2,3}],Above]&),*) (*LabelingFunction\[Rule](Placed[If[#2[[2]]\[Equal]1,NumberForm[#1,{2,3}],""],Above]&),*) PlotLabel->n<>", "<>tau]; @@ -68,9 +70,9 @@ histogramsTotal=MapIndexed[makeHistogram[#1,nlabels[[#2[[2]]]],taulabels[[#2[[1] tauIndices={1,5,9}; -nIndices={3}; -(* TableForm[histogramsTotal[[tauIndices,nIndices]],TableHeadings->{taulabels[[tauIndices]],nlabels[[nIndices]]}] *) -plotgrid1=GraphicsGrid[histogramsTotal[[tauIndices,nIndices]]] +nIndices={1}; +(* TableForm[histogramsTotal[[tauIndices,nIndices]],TableHeadings->{taulabels[[tauIndices]],nlabels[[nIndices]]}]*) +plotgrid1=GraphicsGrid[histogramsTotal[[tauIndices,nIndices]],ImageSize->350,ItemAspectRatio->3/5] Export[NotebookDirectory[]<>"plots/ccm_initialtris.pdf",plotgrid1]