Function Map and sensorvalue constant

I have this code:

const int greenLEDPin = 9;
const int redLEDPin = 11;
const int blueLEDPin = 10;

const int redSensorPin = A0;
const int greenSensorPin = A1;
const int blueSensorPin = A2;
int redValue = 0;
int greenValue = 0;
int blueValue = 0;

int redSensorValue = 0;
int greenSensorValue = 0;
int blueSensorValue = 0;
void setup() {
    Serial.begin(9600);

    pinMode(greenLEDPin, OUTPUT);
    pinMode(redLEDPin, OUTPUT);
    pinMode(blueLEDPin, OUTPUT);
}
void loop() {
    redSensorValue = analogRead(redSensorPin);
    delay(5);
    greenSensorValue = analogRead(greenSensorPin);
    delay(5);
    blueSensorValue = analogRead(blueSensorPin);
    Serial.print("Raw Sensor Values \t Red: ");
    Serial.print(redSensorValue);
    Serial.print("\t Green: ");
    Serial.print(greenSensorValue);
    Serial.print("\t Blue: ");
    Serial.println(blueSensorValue);
    redValue = redSensorValue/4;
    greenValue = greenSensorValue/4;
    blueValue = blueSensorValue/4;
     Serial.print("Mapped Sensor Values \t Red: ");
    Serial.print(redValue);
    Serial.print("\t Green: ");
    Serial.print(greenValue);
    Serial.print("\t Blue: ");
    Serial.println(blueValue);

    analogWrite(redLEDPin, redValue);
    analogWrite(greenLEDPin, greenValue);
    analogWrite(blueLEDPin, blueValue);

And I need add this:

redValue = ((redSensorValue-600)*255)/424;
    greenValue = ((greenSensorValue-600)*255)/424;
    blueValue = ((blueSensorValue-600)*255)/424;

but I need add a “if” when the value of sensors is below 0. For example:

redValue = ((redSensorValue-600)*255)/424;
    greenValue = ((greenSensorValue-600)*255)/424;
    blueValue = ((blueSensorValue-600)*255)/424;
    if(sensorvalue<0) redSensorValue=0; // I need add this "if" for all sensors

How I can make it? Please, Can you help me?
How I can use the function “map”? If I use it, the negative values it’ll be zero?

=map(sensorValue,600,1024,0,253)

You can use map to compress or expand a range of values (eg you read values in the range 0 to 1023 but want to write values in the range 0 to 255)
https://www.arduino.cc/en/Reference/Map

You can use constrain to exclude out of range values (eg values < 0 )
https://www.arduino.cc/en/Reference/Constrain

I guess that what you want to do, based on the additional code you supplied, is this:

const int greenLEDPin = 9;
const int redLEDPin = 11;
const int blueLEDPin = 10;

const int redSensorPin = A0;
const int greenSensorPin = A1;
const int blueSensorPin = A2;
int redValue = 0;
int greenValue = 0;
int blueValue = 0;

int redSensorValue = 0;
int greenSensorValue = 0;
int blueSensorValue = 0;

void setup() {
  Serial.begin(9600);

  pinMode(greenLEDPin, OUTPUT);
  pinMode(redLEDPin, OUTPUT);
  pinMode(blueLEDPin, OUTPUT);
}

void loop() {
  redSensorValue = analogRead(redSensorPin);
  delay(5);
  greenSensorValue = analogRead(greenSensorPin);
  delay(5);
  blueSensorValue = analogRead(blueSensorPin);
  Serial.print("Raw Sensor Values \t Red: ");
  Serial.print(redSensorValue);
  Serial.print("\t Green: ");
  Serial.print(greenSensorValue);
  Serial.print("\t Blue: ");
  Serial.println(blueSensorValue);

  // original Code:
  // redValue = redSensorValue/4;
  // greenValue = greenSensorValue/4;
  // blueValue = blueSensorValue/4;

  // new code
  redValue = ((redSensorValue - 600) * 255) / 424;
  greenValue = ((greenSensorValue - 600) * 255) / 424;
  blueValue = ((blueSensorValue - 600) * 255) / 424;
  if ( redValue < 0 ) {
    redValue = 0 ;
  } ;
  if ( greenValue < 0 ) {
    greenValue = 0 ;
  } ;
  if ( blueValue < 0 ) {
    blueValue = 0 ;
  } ;



  Serial.print("Mapped Sensor Values \t Red: ");
  Serial.print(redValue);
  Serial.print("\t Green: ");
  Serial.print(greenValue);
  Serial.print("\t Blue: ");
  Serial.println(blueValue);

  analogWrite(redLEDPin, redValue);
  analogWrite(greenLEDPin, greenValue);
  analogWrite(blueLEDPin, blueValue);
}

you might have a look at this class I once wrote - http://forum.arduino.cc/index.php?topic=276194.5