Contents Previous Next Subchapters

Determining the Number of Maps in the Current Frame
Syntax tpmapcount()
See Also tpplot , tpmacrostring

Returns an integer scalar specifying the number of maps in the current Tecplot frame.

If you enter
   x = 0. : .1 : 2 * pi
   y = cos(x)
   ix = 0.2
   while (ix < 6.0) begin
      m =tpplot(x+ix,y)
      ix = ix + 1
      print "tpplot() created map number: ", m
O-Matrix will create 6 curves, with 6 line maps and echo the number of each map as it is created,
tpplot() created map number:  1 
tpplot() created map number:  2 
tpplot() created map number:  3 
tpplot() created map number:  4 
tpplot() created map number:  5 
tpplot() created map number:  6 
If you continue by entering
O-Matrix will echo 6 which is the number of maps in the current frame after executing the example above.

The tpmapcount function can also be used to determine the number of maps in existing data sets or files. If you enter,
   print "Number of maps in rainfall.plt = ", tpmapcount
O-Matrix will echo
   Number of maps in rainfall.plt =  5
which is the number of map in the rainfall.plt sample data file.