Hello,

I've tried to get help on this but a bit prematurely so I am trying again.

I have 2 arrays but I need to make them into a multidimensional array but the factors need to change using IF statements and I need this all done in a function for callback in Jpgraph.

Here is my code:

PHP Code:
//the following 2 arrays are pulled from my DB and work
//determine size

$cirsz[0] = 'small';
$cirsz[1] = 'medium';
$cirsz[2] = 'large';

//determine color from these values
$circlr[0] =  23;
$circlr[1] = 20;
$circlr[2] = 18;

//breaksdown somewhere in the function

function SettingSet($cirsz$circlr) {

global 
$cirsz
global 
$circlr
    
// This callback will adjust the fill color and size of
    // the datapoint according to the data value
    
$i 0;
//get sizes
foreach($cirsz as $s){
if(
$s == 'small'){
$sz 15;
}elseif(
$s == 'medium'){
$sz 30;
}else{
$sz 50;
}

if(
$circlr <= 25 && ($circlr >= 18.75)){
$col "red";
}elseif(
$circlr 18.75 && ($circlr >= 12.5)){
$col ="orange";
}elseif(
$circlr 12.5 && ($circlr >= 6.25)){
$col "yellow";
}else{
$col "green";
}
$i++;
}
  return array(
$sz,"",$col); 

I need the array which the function returns to look similar to this:

Code:
array(
$a[0] = 15 => "" => red;
$a[1] = 30 => "" => red;
$a[2] = 50 => "" => orange;
}
Thank You in advance for taking the time to help me.