begin ; ; An application object must be created so that we can have a resource ; file. The resource file should be the name name given to the ; application object ("font" in this case") with a ".res" appended. ; appid = create "font" appClass defaultapp "appDefaultParent" : True end create ; ; Create an X Workstation. ; wks = create "wks" xWorkstationClass defaultapp end create ; ; Create a data object. ; dataid = create "data" coordArraysClass appid "caYArray" : (/1,3,-1,-2,0,2,3/) end create ; ; Create an XY plot. ; xy = create "xyplot" xyPlotClass wks "xyCoordData" : dataid "tiMainString" : "This is an XY plot" "tiXAxisString" : "X values" "tiYAxisString" : "Y values" end create draw(xy) ; Draw the plot. frame(wks) ; Advance the frame. end