Crosshair Demo

버전 1.0.0.0 (101 KB) 작성자: Sven Koerner
Demonstration of crosshair in figure. Uses JFreeChart and Matlab
다운로드 수: 887
업데이트 날짜: 2011/2/16

라이선스 보기

CrosshairDemo alá JFreeGraph-Demo

The code behind is just a demo of what is possible with JFreeChart using it in Matlab. I played a little
with codesnippets I found on the web and the API-Documentation.
(http://www.jfree.org/jfreechart/api/javadoc/index.html). When you want to explore the whole functionality,
I think it is better to buy the JFreeChart Developer Guide (http://www.jfree.org/jfreechart/devguide.html).

This function shows a single domain and range axis plot (Sinus function) with crosshair-functionality as an
example of JFreeChart (http://www.jfree.org/). The Idea to this code is based on the UndocumentedMatlab-Blog
of Yair Altman, who shows a sample Code of JFreeChart for creating a PieChart
(http://undocumentedmatlab.com/blog/jfreechart-graphs-and-gauges/#comments)

Within the plot you can zoom by pressing the left mouse button and moving the pointer. Also you have some
properties by right-clicking on the chart.
With the slider or by mousclick in the chart you can set the position of the crosshair. The actual values of
the crosshair are displayed in the table.

Before this demo works, you need to download JFreeChart and make matlab get to know with it. There are 2
ways you can do this:
1. Add the jcommon and jfreechart jar to the dynamic matlab JavaClassPath (uncommented lines in the first
cell an change path to your local installation path)
2. Add the jcommon and jfreechart jar to the static matlab JavaClassPath (see Matlab Help, modify
classpath.txt on matlabroot\toolbox\local)

Finally you must donwload jcontrol from Malcom Lidierth
(http://www.mathworks.com/matlabcentral/fileexchange/15580-using-java-swing-components-in-matlab).

Bugs and suggestions:
Please send to Sven Koerner: koerner(underline)sven(add)gmx.de

You need to download and install first:
http://sourceforge.net/projects/jfreechart/files/1.%20JFreeChart/1.0.13/
http://sourceforge.net/projects/jfreechart/files/1.%20JFreeChart/1.0.9/
http://www.mathworks.com/matlabcentral/fileexchange/15580-using-java-swing-components-in-matlab

인용 양식

Sven Koerner (2024). Crosshair Demo (https://www.mathworks.com/matlabcentral/fileexchange/30440-crosshair-demo), MATLAB Central File Exchange. 검색됨 .

MATLAB 릴리스 호환 정보
개발 환경: R2010a
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
버전 게시됨 릴리스 정보
1.0.0.0