Hi Brian,
I was able to figure this out yesterday using Igor Pro programming.
Yes, you are right on how Visual Minteq works to make a similar plot. Thanks for the other suggestions. It will be an interesting challenge to figure it out for a multi-mineral plot. Then on to an E-pH diagram...
I'm not sure if many folks use Igor Pro in the geochemistry world or not beyond our little bubble, but if so, here is my code. It isn't terribly pretty and I am sure there are things wrong with it, but I get the same graph out of the data as GWB.
Best,
Drew
Function findAssemblageLine(arrayData, xData, yData, nameOfOutputYWave, nameOfOutputXWave)
WAVE arrayData //array data is an i row by j column table from the output of Geochemists Workbench "color map" outpu
WAVE yData
Wave xData
String nameOfOutputYWave //Y data, usually concentration or activity of the y variable
String nameOfOutputXWave //X data, pH
int arrayRow // i rows in array data
int arrayCol // j columns in array data
int waveOutYDimSize = DimSize(arrayData, 0) // waveOutYDimSize is the number of points in the Y direction
int waveOutXDimSize = DimSize(arrayData, 0) // waveOutXDimSize has to be the number of points in the Y direction of the
MAKE /O/N=(waveOutYDimSize) $nameOfOutputYWave //Make output Y wave (overwrites an existing wave)
MAKE /O/N=(waveOutXDimSize) $nameOfOutputXWave //Make output X wave (overwrites an existing wave)
WAVE waveOutY = $nameOfOutputYWave //Tie local wave to global wave names
WAVE waveOutX = $nameOfOutputXWave
//step through rows for loop
for(arrayRow = 0; arrayRow < DimSize(arrayData, 0);arrayRow++) //ROW For loop
for(arrayCol = 0; arrayCol < DimSize(arrayData, 1); arrayCol++) //INNER Column For loop
if(arrayData[arrayRow][arrayCol] != 0 && arrayData[arrayRow][arrayCol+1] == 0) //Evaluate if point at (Row,Column) is not equil to zero and the next column in the row is equal to zero.
waveOutY[arrayRow] = yData[arrayRow] //Take the value of yData at arrayRow and put it into a new wave
waveOutX[arrayRow] = xData[arrayCol+1] //Take the value of xData at the next column over (i.e., the point where the value is 0) in put it into a new wave
endif
endfor
endfor
End