original_string: private function format_float($value) {
          if (is_numeric($value)) {
              if ($value > 0) {
                  $decimals = strlen($value) - strlen(floor($value)) - 1;
              } else {
                  $decimals = strlen($value) - strlen(ceil($value)) - 1;
              }
              $value = format_float($value, $decimals);
          }
          return $value;
      }
code: private function format_float($value) {
          if (is_numeric($value)) {
              if ($value > 0) {
                  $decimals = strlen($value) - strlen(floor($value)) - 1;
              } else {
                  $decimals = strlen($value) - strlen(ceil($value)) - 1;
              }
              $value = format_float($value, $decimals);
          }
          return $value;
      }
code_tokens: private function format_float ( $ value ) { if ( is_numeric ( $ value ) ) { if ( $ value > 0 ) { $ decimals = strlen ( $ value ) - strlen ( floor ( $ value ) ) - 1 ; } else { $ decimals = strlen ( $ value ) - strlen ( ceil ( $ value ) ) - 1 ; } $ value = format_float ( $ value , $ decimals ) ; } return $ value ; }
docstring: Given a float, prints it nicely.
  This function reserves the number of decimal places.
  
  @param float|null $value The float number to format
  @return string Localised float
docstring_tokens: Given a float prints it nicely . This function reserves the number of decimal places .