4
$\begingroup$

I have a 12*25 array, wherein each entry is of the form $\{x,y,z\}$. So 12 different $x$ values, 25 different $y$ values and 12*15 $z$ values in all.
I'd like to plot 12 curves of various $x$ values with each curve being a function of $y$. That is something like these two below. In addition, it's better that the original data points are visible and 12 curves can be discernible in terms of $x$ values via color and/or other methods.

enter image description here

The data :

data={{{0.0,0.1,544.5290821},{0.0,0.12,317.9272105},{0.0,0.15,303.7115037},{0.0,0.2,147.8843437},{0.0,0.25,71.16087134},{0.0,0.3,42.01728833},{0.0,0.4,17.04187462},{0.0,0.5,10.47886759},{0.0,0.6,7.087340705},{0.0,0.7,3.865883217},{0.0,0.8,3.026162655},{0.0,0.9,2.577267866},{0.0,1.0,2.006568314},{0.0,1.2,1.187787123},{0.0,1.5,0.7450057751},{0.0,2.0,0.290757454},{0.0,2.5,0.1709376726},{0.0,3.0,0.1015780328},{0.0,4.0,0.03707232976},{0.0,5.0,0.01635099238},{0.0,6.0,0.009965256358},{0.0,7.0,0.006499650839},{0.0,8.0,0.00420646533},{0.0,9.0,0.002955965421},{0.0,10.0,0.002143785229}},{{0.1,0.1,533.4617743},{0.1,0.12,994.4024251},{0.1,0.15,256.836771},{0.1,0.2,128.1365043},{0.1,0.25,74.64665329},{0.1,0.3,36.36893127},{0.1,0.4,25.86592311},{0.1,0.5,11.64411579},{0.1,0.6,6.611596417},{0.1,0.7,4.218899023},{0.1,0.8,2.933009097},{0.1,0.9,2.579442403},{0.1,1.0,1.976079947},{0.1,1.2,1.417675289},{0.1,1.5,0.7065992145},{0.1,2.0,0.03966675362},{0.1,2.5,0.1787197849},{0.1,3.0,0.1108957338},{0.1,4.0,0.03868364847},{0.1,5.0,0.01686629461},{0.1,6.0,0.01057010271},{0.1,7.0,0.006851619379},{0.1,8.0,0.004764092252},{0.1,9.0,0.003150531905},{0.1,10.0,0.002318932646}},{{0.2,0.1,603.3481096},{0.2,0.12,671.0146397},{0.2,0.15,266.6526257},{0.2,0.2,154.9701996},{0.2,0.25,76.57697863},{0.2,0.3,41.26030311},{0.2,0.4,17.28220011},{0.2,0.5,11.35284596},{0.2,0.6,6.831283616},{0.2,0.7,4.54205755},{0.2,0.8,3.217811501},{0.2,0.9,2.73941943},{0.2,1.0,2.165353459},{0.2,1.2,1.353295151},{0.2,1.5,0.7916002866},{0.2,2.0,0.3363254364},{0.2,2.5,0.1930290881},{0.2,3.0,0.1165442108},{0.2,4.0,0.03863095593},{0.2,5.0,0.01770086373},{0.2,6.0,0.01127402615},{0.2,7.0,0.007190122141},{0.2,8.0,0.004553603873},{0.2,9.0,0.003268984244},{0.2,10.0,0.002364645177}},{{0.4,0.1,891.5208123},{0.4,0.12,497.163557},{0.4,0.15,328.7459606},{0.4,0.2,237.3092113},{0.4,0.25,116.5148524},{0.4,0.3,69.0645462},{0.4,0.4,25.47406819},{0.4,0.5,16.05068139},{0.4,0.6,10.33733361},{0.4,0.7,6.475049787},{0.4,0.8,5.896226077},{0.4,0.9,4.002148022},{0.4,1.0,3.086759572},{0.4,1.2,2.010720095},{0.4,1.5,1.106580939},{0.4,2.0,0.4843317016},{0.4,2.5,0.2550470329},{0.4,3.0,0.1677943701},{0.4,4.0,0.05479746563},{0.4,5.0,0.02715589754},{0.4,6.0,0.01620421063},{0.4,7.0,0.01013247822},{0.4,8.0,0.006546351875},{0.4,9.0,0.004427418558},{0.4,10.0,0.003539126809}},{{0.6,0.1,2283.285106},{0.6,0.12,2436.484485},{0.6,0.15,780.620969},{0.6,0.2,369.2014963},{0.6,0.25,264.4490685},{0.6,0.3,140.6140044},{0.6,0.4,71.28059748},{0.6,0.5,29.685109},{0.6,0.6,23.9001713},{0.6,0.7,12.25023497},{0.6,0.8,11.59454174},{0.6,0.9,7.73239968},{0.6,1.0,6.025010196},{0.6,1.2,3.979645325},{0.6,1.5,2.072218022},{0.6,2.0,0.9348596804},{0.6,2.5,0.4809793121},{0.6,3.0,0.3134349187},{0.6,4.0,0.1092997717},{0.6,5.0,0.05180386474},{0.6,6.0,0.03147453316},{0.6,7.0,0.01970144553},{0.6,8.0,0.01274097893},{0.6,9.0,0.009275249842},{0.6,10.0,0.00680813529}},{{0.8,0.1,2693.368219},{0.8,0.12,2219.503399},{0.8,0.15,1228.723357},{0.8,0.2,653.0804944},{0.8,0.25,432.3464167},{0.8,0.3,262.3514466},{0.8,0.4,166.9278694},{0.8,0.5,65.47567947},{0.8,0.6,33.37227577},{0.8,0.7,29.01833466},{0.8,0.8,26.2574645},{0.8,0.9,12.79878997},{0.8,1.0,9.576932293},{0.8,1.2,6.689586323},{0.8,1.5,3.791258328},{0.8,2.0,1.836291366},{0.8,2.5,0.9356165692},{0.8,3.0,0.5667638961},{0.8,4.0,0.1868472718},{0.8,5.0,0.0904072265},{0.8,6.0,0.05096407224},{0.8,7.0,0.03495066575},{0.8,8.0,0.02168385154},{0.8,9.0,0.01517582953},{0.8,10.0,0.01048589866}},{{0.9,0.1,2441.863795},{0.9,0.12,1508.758113},{0.9,0.15,1003.925407},{0.9,0.2,636.5455829},{0.9,0.25,394.4257501},{0.9,0.3,226.1298467},{0.9,0.4,93.89262558},{0.9,0.5,90.49115032},{0.9,0.6,34.22374506},{0.9,0.7,22.46570727},{0.9,0.8,15.75593864},{0.9,0.9,11.69643005},{0.9,1.0,9.573868541},{0.9,1.2,6.800292926},{0.9,1.5,3.609915782},{0.9,2.0,1.569823475},{0.9,2.5,0.8522499462},{0.9,3.0,0.5217609389},{0.9,4.0,0.174272733},{0.9,5.0,0.08668529045},{0.9,6.0,0.04901223217},{0.9,7.0,0.03151505729},{0.9,8.0,0.02154165321},{0.9,9.0,0.01452029402},{0.9,10.0,0.01033995851}},{{1.0,0.1,6084.892374},{1.0,0.12,1917.581591},{1.0,0.15,1055.485222},{1.0,0.2,686.6650971},{1.0,0.25,327.8622258},{1.0,0.3,249.3484563},{1.0,0.4,105.0849315},{1.0,0.5,59.4413843},{1.0,0.6,32.13505206},{1.0,0.7,22.66226696},{1.0,0.8,15.64996264},{1.0,0.9,12.39648073},{1.0,1.0,9.800108007},{1.0,1.2,6.110935535},{1.0,1.5,3.515101855},{1.0,2.0,1.480943061},{1.0,2.5,0.8578045679},{1.0,3.0,0.5082307187},{1.0,4.0,0.1765273188},{1.0,5.0,0.07957088771},{1.0,6.0,0.05013623584},{1.0,7.0,0.02989181163},{1.0,8.0,0.02062943939},{1.0,9.0,0.01508442091},{1.0,10.0,0.01018630915}},{{1.1,0.1,5587.309871},{1.1,0.12,2151.084765},{1.1,0.15,1971.900125},{1.1,0.2,977.0965406},{1.1,0.25,517.1637941},{1.1,0.3,308.2228368},{1.1,0.4,154.2791882},{1.1,0.5,73.1152429},{1.1,0.6,44.59729391},{1.1,0.7,23.85734637},{1.1,0.8,23.71268834},{1.1,0.9,15.15087488},{1.1,1.0,14.15680392},{1.1,1.2,8.630329987},{1.1,1.5,4.794602499},{1.1,2.0,1.957483158},{1.1,2.5,1.104456365},{1.1,3.0,0.6847599086},{1.1,4.0,0.2283797058},{1.1,5.0,0.1067571545},{1.1,6.0,0.0624613694},{1.1,7.0,0.04039668981},{1.1,8.0,0.02580860258},{1.1,9.0,0.01807499314},{1.1,10.0,0.01415569715}},{{1.2,0.1,4164.453439},{1.2,0.12,4545.287862},{1.2,0.15,2421.073664},{1.2,0.2,1226.94888},{1.2,0.25,722.3353724},{1.2,0.3,462.3288227},{1.2,0.4,214.4645374},{1.2,0.5,107.3058066},{1.2,0.6,67.62150917},{1.2,0.7,37.03172479},{1.2,0.8,28.80713612},{1.2,0.9,25.43153706},{1.2,1.0,16.82730276},{1.2,1.2,14.09331035},{1.2,1.5,7.170393913},{1.2,2.0,2.896140096},{1.2,2.5,1.653125217},{1.2,3.0,0.9687954093},{1.2,4.0,0.3162908705},{1.2,5.0,0.151699507},{1.2,6.0,0.09360931908},{1.2,7.0,0.06019528083},{1.2,8.0,0.03762907646},{1.2,9.0,0.02811320466},{1.2,10.0,0.0198520522}},{{1.4,0.1,8236.314655},{1.4,0.12,4836.300897},{1.4,0.15,2098.945446},{1.4,0.2,1716.251498},{1.4,0.25,830.9983541},{1.4,0.3,499.7441392},{1.4,0.4,231.8145463},{1.4,0.5,121.8951661},{1.4,0.6,72.26179255},{1.4,0.7,69.11735894},{1.4,0.8,43.48609849},{1.4,0.9,37.19931242},{1.4,1.0,23.24327713},{1.4,1.2,14.24973452},{1.4,1.5,8.564273083},{1.4,2.0,3.577710864},{1.4,2.5,1.889226696},{1.4,3.0,1.134167819},{1.4,4.0,0.3802416305},{1.4,5.0,0.1985214906},{1.4,6.0,0.1092341444},{1.4,7.0,0.07047733105},{1.4,8.0,0.04816233404},{1.4,9.0,0.03156027608},{1.4,10.0,0.02407256048}},{{1.6,0.1,29.52066924},{1.6,0.12,22.71601945},{1.6,0.15,30.84142768},{1.6,0.2,13.77066818},{1.6,0.25,8.060411067},{1.6,0.3,4.741210292},{1.6,0.4,2.338522635},{1.6,0.5,1.945226175},{1.6,0.6,1.225388715},{1.6,0.7,1.014778098},{1.6,0.8,0.7835036175},{1.6,0.9,0.6338702535},{1.6,1.0,0.4735900446},{1.6,1.2,0.3054580288},{1.6,1.5,0.1598250625},{1.6,2.0,0.0573159134},{1.6,2.5,0.02839756906},{1.6,3.0,0.01880761962},{1.6,4.0,0.008210913309},{1.6,5.0,0.003957314909},{1.6,6.0,0.00192907335},{1.6,7.0,0.001438041179},{1.6,8.0,0.0008386913523},{1.6,9.0,0.0006333051914},{1.6,10.0,0.0004062951405}}};
$\endgroup$
3
  • $\begingroup$ Does this do what you want, ListPointPlot3D[data] /. Point -> Line? $\endgroup$ Commented Jan 14, 2015 at 4:20
  • $\begingroup$ @Algohi would you consider answering? $\endgroup$
    – Yves Klett
    Commented Jan 14, 2015 at 8:09
  • $\begingroup$ @YvesKlett, Done. Thank you. $\endgroup$ Commented Jan 14, 2015 at 14:02

3 Answers 3

3
$\begingroup$
ListPointPlot3D[data, 
  PlotStyle -> Directive[PointSize[0.02], Thickness[0.01]]] /. 
 Point[x_] -> Through[{Point, Line}[x]]

enter image description here

$\endgroup$
3
$\begingroup$

Using ListPlot3D with Mesh:

data = Table[{i, j, Sin[j^2 + i]}, {j, 0, 2 Pi, 2 Pi/11}, {i, 0, 2 Pi, 2 Pi/24}];
Dimensions[data]
(* {12, 25, 3} *)

colors = Directive[Thick, #] & /@ ColorData["Rainbow"] /@ Range[0, 1, 1/11];

lp3d = ListPlot3D[Join @@ data, PlotStyle -> Opacity[0.3], BoundaryStyle -> None,
  Mesh -> {0, Thread[{Range[0, 2 Pi, 2 Pi/11], colors}]}]

enter image description here

Show[ListPlot3D[Join @@ data, PlotStyle -> Opacity[0.3], BoundaryStyle -> None, 
  Mesh -> {0, Thread[{Range[0, 2 Pi, 2 Pi/11], colors}]}], 
 ListPointPlot3D[data, PlotStyle -> colors], BaseStyle -> PointSize[Large]]

enter image description here

Alternatively, you can post-process Lines in the ListPlot3D output into Points and Lines to get the same picture:

lp3d /. Line[x__] :> {PointSize[Large], Point@x, Line@x}
$\endgroup$
2
$\begingroup$
d = data /. {x_Real, y_Real, z_Real} -> {{x, y}, z};
dat = Flatten[d, 1];
int = Interpolation[dat];

Plot3D[int[x, y], {x, 0, 1.6}, {y, 0.1, 10},
 Mesh -> {data[[All, 1]][[All, 1]], data[[1, All]][[All, 2]]},
 PlotStyle -> Opacity[0.5], MeshStyle -> {Red, Blue}]

enter image description here

The idea is to use Mesh option for drowing lines on surface obtained from multidimentional interpolation of your data

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.