That's a way
ListPlot[RandomReal[{-20, 20}, 100] /. x_Real :> If[Abs[x] > 10., 0, x], PlotRange -> {Automatic, {-11, 11}}]
please note, if angle1
is a list (because it appears in ListPlot[]
) then Abs[angle1]
threads over the list angle1
and Abs[angle1] < 10
is meaningless and comes back unevaluated. Just try subexpressions before using them:
In[9]:= l = {1, -2, 3, -4, 5, -5, 7};
In[10]:= Abs[l]
Out[10]= {1, 2, 3, 4, 5, 5, 7}
In[11]:= Abs[l] < 10
Out[11]= {1, 2, 3, 4, 5, 5, 7} < 10