source: trunk/SRC/Tests/tst_basic.pro @ 237

Last change on this file since 237 was 237, checked in by pinsard, 17 years ago

replace some print by some report in some .pro (continuation) + improvements/corrections of some *.pro headers

  • Property svn:keywords set to Id
File size: 932 bytes
Line 
1;+
2;
3; @file_comments
4; figure 1: basics plots
5; plot and contours
6;
7; @history
8; Sebastien Masson may 2005
9;
10; @version
11; $Id$
12;
13;-
14;
15PRO tst_basic
16;
17; 1) plot
18;
19  compile_opt idl2, strictarrsubs
20;
21  n = 10
22  y = findgen(n)
23; basic plot
24  splot, y, small = [2, 2, 1], /portrait
25; improved plot by using plot and "graphic keywords"
26  splot, y, small = [2, 2, 2], /noerase, yrange = [0, (n-1)^2], title = 'x and x^2'
27  oplot, y^2, color = 100, linestyle = 2, thick = 3
28;
29; 2) contour
30;
31  z = dist(n)
32; basic plot
33  scontour, z, /fill, nlevels = 15, small = [2, 2, 3], /noerase
34; improved plot by using contour and "graphic keywords"
35  ind = findgen(2*n)/(2.*n)
36  scontour, z, levels = n*ind, c_orientation = 180*ind, c_spacing = .2*ind $
37            , small = [2, 2, 4], /noerase
38  contour, z, /overplot, c_label = rebin([1, 0], 2, n), levels = n*ind $
39           , c_charthick = 2, c_charsize = 1.5, c_colors = 250*ind
40  return
41end
Note: See TracBrowser for help on using the repository browser.