I have a *.xlsx
file containing four columns, each pair representing an x
and y
value, so (from left to right): x_sample1
, y_sample1
, x_sample2
, y_sample2
.
What I wanted to do, is put them in a ListLinePlot
(or something similar) next to each other in a 3-D view. I managed to get what I wanted using ListPointPlot
, but a continuous line for each sample would look better for my purposes. ListPointPlot
(to my knowledge) only let me use Filling
to simulate a more continuous, solid look - but that doesn't really cut it. Attached below is a picture of what I did so far and how the general look of it should be.
I used a (rather ugly) workaround to get this to work: for each plot I added an artificial x value named "row" in integer values from 1-14 and these were followed by the original plot data corresponding to y and z data for this plot.
The code I used is:
ListPointPlot3D[{exceldaten[[All, {1, 2, 3}]], exceldaten[[All, {4, 5, 6}]],
exceldaten[[All, {7, 8, 9}]], exceldaten[[All, {10, 11, 12}]],
exceldaten[[All, {13, 14, 15}]], exceldaten[[All, {16, 17, 18}]],
exceldaten[[All, {19, 20, 21}]], exceldaten[[All, {22, 23, 24}]],
exceldaten[[All, {25, 26, 27}]], exceldaten[[All, {28, 29, 30}]],
exceldaten[[All, {31, 32, 33}]], exceldaten[[All, {34, 35, 36}]],
exceldaten[[All, {37, 38, 39}]], exceldaten[[All, {40, 41, 42}]]},
PlotRange -> {{0.5, 14.5}, {0.0002, 0.0006}, {0, 50000}},
Filling -> Axis, FillingStyle -> Automatic, Axes -> {False, True,True},
AxesLabel -> {None, "mobility (corresponding unit)", "cps"},
Ticks -> {header[[3 ;; 42 ;; 3]], Automatic, Automatic},
LabelStyle -> Directive[Bold, Medium], PlotLegends -> header[[3 ;; 42 ;; 3]]]
Comments
Post a Comment