public static double log10(double val){
  if (val > 0.0)   return Math.log10(val);
  return HUGE_NEGATIVE;
}

public static double log10 ( double val ) { if ( val > 0.0 ) return Math . log10 ( val ) ; return HUGE_NEGATIVE ; }
adjusted log10 to handle values less or equal to zero . < p > the logarithm does not result in real numbers for arguments less or equal to zero , but the plot should still somehow handle such values without crashing . so anything & le ; 0 is mapped to a ' really big negative ' number just for the sake of plotting . < p > note that logarithmicaxis . java in the jfreechart has another interesting idea for modifying the log10 of values & le ; 10 , resulting in a smooth plot for the full real argument range . unfortunately that clobbers values like 1e - 7 , which might be a very real vacuum reading .
