Skip to main content

plotting - A topoplot function for Mathematica



Matlab's EEGlab toolbox has a topoplot function:


http://sccn.ucsd.edu/eeglab/


A typical topographical plot of an EEG signal is given below:


enter image description here


How can I reproduce this in Mathematica. I know that ContourPlot and ListCountourPlot provide such functionalities, however, the data is on a square grid... and I would like it on a circle like in the figure...



Answer



RegionFunction is the option you are looking for.


ContourPlot[
Evaluate[Sum[Sin[RandomReal[5, 2].{x, y}], {5}]], {x, -3, 3}, {y, -3, 3},
BoundaryStyle -> {Thick, Black},

RegionFunction -> Function[{x, y, z}, x^2 + y^2 < 9]
]

enter image description here


Comments