Logging Data from Wii Nunchuk

Hi,

Im having minor issues with logging data onto an SD card.
Ive managed to connect an accelerometer from a wii nunchuk remote and code it to show acceleration on the X,Y&Z axis onto the Serial Plotter.
Im quite new to this, and all I want is to log this data onto an SD card where it will give me an excel file with all the data from the accelerometer.

Ive attached the code written so far.

Nunchuk_Accelerometer.ino (1.02 KB)

What errors are you getting?
Is the SD card formatted as FAT16?