0
$\begingroup$

This question already has an answer here:

Subscript[[Alpha], 1]={1.50,1.75,1.90,1.95}; c1={0.670,0.860,0.950,0.970}; c2={0.440,0.570,0.630,0.650}; c3={0.400,0.510,0.570,0.580}; c4={0.380,0.490,0.540,0.560}; g1=ListLinePlot[{c1,c2,c3,c4},Frame->True, FrameLabel->{Style["!(*SubscriptBox[([Alpha]), (1)])", Medium, Bold, Black], Style["[Rho]", Bold, Black,10]}, FrameStyle->{Directive[Bold,Black,12],Directive[Bold,Black,12]}, PlotLegends->Placed[{"!(*SubscriptBox[([Alpha]), (2)])=2", "!(*SubscriptBox[([Alpha]), (2)])=4", "!(*SubscriptBox[([Alpha]), (2)])=6", "!(*SubscriptBox[([Alpha]), (2)])=8"}, {0.2, 0.6}], PlotTheme -> "Monochrome", PlotLabel->Style["(a):Utilization Factor", Black,Bold,10]](*You lost a square bracket in the right had for ListLinePlot *)

My problem is the values of $\alpha_1$ are not shown on the x-axis. How can I get these values on the x-axis?

Edit

[I am adding a major edit of the OP's code dump so readers can see what the problem is -- m_goldberg]

Subscript[α, 1] = {1.50, 1.75, 1.90, 1.95}; 
c1 = {0.670, 0.860, 0.950, 0.970};
c2 = {0.440, 0.570, 0.630, 0.650}; 
c3 = {0.400, 0.510, 0.570, 0.580}; 
c4 = {0.380, 0.490, 0.540, 0.560}; 
ListLinePlot[{c1, c2, c3, c4},
  Frame -> True, 
  FrameLabel -> 
    {Style[HoldForm[Subscript[α, 1]], Medium, Bold, Black], 
     Style["ρ", Bold, Black, 10]}, 
  FrameStyle -> {Directive[Bold, Black, 12], Directive[Bold, Black, 12]}, 
  PlotLegends -> 
    Placed[HoldForm[Subscript[α, 2] = #] & /@ {2, 4, 6, 8}, {0.8, 0.22}],
  PlotTheme -> "Monochrome", 
  PlotLabel -> Style["(a):Utilization Factor", Black, Bold, 10]]

plot

$\endgroup$

marked as duplicate by Jason B., user9660, Edmund, Yves Klett, m_goldberg May 18 '16 at 12:02

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

  • $\begingroup$ Perhaps look at the documentation for Ticks? $\endgroup$ – Bill May 18 '16 at 3:27
  • $\begingroup$ You might try adding the option DataRange -> MinMax[Subscript[α, 1]] $\endgroup$ – m_goldberg May 18 '16 at 13:01
6
$\begingroup$
a1 = {1.50, 1.75, 1.90, 1.95};

c1 = {0.670, 0.860, 0.950, 0.970};
c2 = {0.440, 0.570, 0.630, 0.650};
c3 = {0.400, 0.510, 0.570, 0.580};
c4 = {0.380, 0.490, 0.540, 0.560};

data = (Transpose[{a1, #}] & /@ {c1, c2, c3, c4});

g1 = ListLinePlot[data,
  Frame -> True, 
  FrameLabel -> {Style[Subscript[α, 1], Medium, Bold, Black], 
    Style["ρ", Bold, Black, 10]}, 
  FrameStyle -> Directive[Bold, Black, 12],
  PlotLegends -> Placed[{
     Row[{Subscript[α, 2], " = 2"}],
     Row[{Subscript[α, 2], " = 4"}],
     Row[{Subscript[α, 2], " = 6"}],
     Row[{Subscript[α, 2], " = 8"}]},
    {0.8, 0.25}],
  PlotTheme -> "Monochrome",
  PlotLabel -> Style["(a):Utilization Factor", Black, Bold, 12]]

enter image description here

$\endgroup$
  • 1
    $\begingroup$ Woah, MMA sure can make nice plots with the (almost) default settings now! I had a moment of disbelief at first. +1 $\endgroup$ – LLlAMnYP May 18 '16 at 6:53
  • $\begingroup$ Dear Bob Hanlon Thanks $\endgroup$ – Amin May 19 '16 at 5:59

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