Smoothing multiple analog inputs

I have a 3 axis accelerometer and I want to smooth the outputs. Something is wrong in my code because all i'm getting on the serial monitor is 3 arbitrary characters.

//354 = 0m/s^2
//441 = 9.81m/s^2

  const int numAxis = 3;                            //define the number of channels
  const int inputs[numAxis] = {A1, A2, A3};         //define where each axis is
  const int numReadings = 10;                       //define sample size
  int xyz[numAxis];                                 //define array
  int totals[numAxis];                              //totals                           
  int readings[numAxis];                            //averages
  
void setup() {
  Serial.begin(9600);

}

void loop() {
  for(int index = 0; index < numReadings; index++){   //loop 10x
    for(int axis = 0; axis < numAxis; axis++){        //read each axis
      xyz[axis] = analogRead(inputs[axis]);           //read current axis
    }
    totals[index] = xyz[numAxis] + totals[index];     //add to totals
  }
  readings[numAxis] = totals[numAxis] / numReadings;  //divide by 10 to get average

  String values = String(readings[0]) + ", " + String(readings[1]) + ", " + String(readings[2]); 
  
Serial.println(values);                                     //turn the array into a string and println
}

Where is the error in my logic?

UPDATE:

I replaced the totals[index] with totals[numAxis] and now I get a steady output of all zeros. Something is wrong with the math now because all I get are zeros.

//354 = 0m/s^2
//441 = 9.81m/s^2

  const int numAxis = 3;                            //define the number of channels
  const int inputs[numAxis] = {A1, A2, A3};         //define where each axis is
  const int numReadings = 10;                       //define sample size
  int xyz[numAxis];                                 //define array
  int totals[numAxis];                              //totals                           
  int readings[numAxis];                            //averages
  
void setup() {
  Serial.begin(9600);

}

void loop() {
  for(int index = 0; index < numReadings; index++){   //loop 10x
    for(int axis = 0; axis < numAxis; axis++){        //read each axis
      xyz[axis] = analogRead(inputs[axis]);           //read current axis
    }
    totals[numAxis] = xyz[numAxis] + totals[numAxis];     //add to totals
  }
  readings[numAxis] = totals[numAxis] / numReadings;  //divide by 10 to get average

  String values = String(readings[0]) + ", " + String(readings[1]) + ", " + String(readings[2]); 
  
Serial.println(values);                                     //turn the array into a string and println
}
    totals[index] = xyz[numAxis] + totals[index];     //add to totals

The numAxis variable contains 3. The valid index values for xyz are 0, 1, and 2. You are stuffing garbage in totals.

Why do you need to keep an array of values? Just increment totals[n] as you take a reading.

    totals[numAxis] = xyz[numAxis] + totals[numAxis];     //add to totals

Now, you are accessing beyond the end of both arrays.