3
$\begingroup$
s = Import["Desktop/tension.xlsx"];
ListContourPlot[s, Contours -> 10, PlotLegends -> Automatic]

In fact, it is a contour of a circular part from (2,0) (4,0) to (0,4) (0,2). However, I cannot get a contour on a sector of a circle. It has unnecessary part. How can I delete that red part to make it like the other plot from matlab?

Thanks a lot!!!:)

enter image description hereenter image description here

$\endgroup$
0

1 Answer 1

3
$\begingroup$

Use the option RegionFunction:

ss = Table[Sin[i + j^2] + RandomReal[], {i, 0, 3, 0.1}, {j, 0, 3, 0.1}];

ListContourPlot[ss, Contours -> 10, PlotLegends -> Automatic, 
 RegionFunction -> Function[{x, y, z}, 20 <= Norm[{x, y}] < 30]]

enter image description here

$\endgroup$
1
  • 1
    $\begingroup$ @Windy, my pleasure. Welcome to mma.se. $\endgroup$
    – kglr
    Apr 12, 2015 at 23:49

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