A LB enthusiast wanted to process data files about sample down a bore- these are the kind of thing we endded with.
nomainwin WindowWidth = 520 WindowHeight = 700 open "Miner49er" for graphics_nsb as #wg global assayOpen, lithosOpen #wg "goto 0 20 ; down ;fill 200 180 170 ; goto 700 20 ; trapclose quit ; flush" oldLevel = 0 vScale = 9 open "export_lithos.csv" for input as #lithos lithosOpen =1 while eof( #lithos) =0 and Level <700 /vScale line input #lithos, n$ if word$( n$, 1, ",") ="CSH-11-001" then Level =int( 0.5 +val( word$( n$, 2, ","))) rockCode$ =word$( n$, 5, ",") col$ =lookUp$( rockCode$) print Level, rockCode$, col$ #wg "backcolor "; col$ #wg "place 20 "; 20 +vScale *oldLevel; " ; boxfilled 50 "; 20 +vScale *Level 'print "#wg 'place 20 "; 20 +vScale *oldLevel; " ; boxfilled 50 "; 20 +vScale *Level; "'" oldLevel =Level end if wend close #lithos lithosOpen =0 print: print Level =0 #wg "color red ; size 4 ; flush ; discard ; down" open "export_assay.csv" for input as #assay assayOpen =1 while eof( #assay) =0 and Level <700 /vScale line input #assay, n$ if word$( n$, 1, ",") ="CSH-11-001" then Level =int( 0.5 +val( word$( n$, 2, ","))) Au =val( word$( n$, 5, ",")) 'print "#wg 'set 40 "; 20 +vScale *Level; "'" #wg "up ; goto 50 "; 20 +vScale *Level; " ; down ; goto "; 50 +Au *100; " "; 20 +vScale *Level end if wend close #assay assayOpen =0 #wg "flush ; getbmp scr 0 0 519 719" bmpsave "scr", "Hole CSH-11-001.bmp" wait ' _______________________________________________________ function lookUp$( r$) ' so can colour-code graphic output.... select case r$ case " S" lookUp$ ="200 200 200" case " mC2" lookUp$ ="200 100 0" case " mC1" lookUp$ ="100 200 50" case " mAC" lookUp$ ="70 120 30" case " mC3" lookUp$ ="100 0 50" 'case " mC1" 'lookUp$ ="50 0 250" case else lookUp$ ="120 120 190" end select end function sub quit h$ close #wg if lithosOpen then close #lithos if assayOpen then close #assay end end sub