close all

mass=[0; 249; 454; 713; 962; 1167; 1379; 1833; 2082; 2195; 2400; 2659];

figure;
blue=[46; 51; 59; 68; 82; 99; 116; 155; 177; 195; 205; 219];
blue_param=robustfit(mass,blue)
blue_linear=blue_param(1)+blue_param(2)*mass;
blue_corr=corr(mass,blue)
plot(mass,blue,mass,blue_linear)

figure;
green=[44; 49; 57; 70; 85; 104; 125; 169; 194; 190; 216; 223];
green_param=robustfit(mass,green)
green_linear=green_param(1)+green_param(2)*mass;
green_corr=corr(mass,green)
plot(mass,green,mass,green_linear)

figure;
brown=[43; 52; 63; 73; 81; 89; 99; 122; 139; 154; 166; 178];
brown_param=robustfit(mass,brown)
brown_linear=brown_param(1)+brown_param(2)*mass;
brown_corr=corr(mass,brown)
plot(mass,brown,mass,brown_linear)

figure;
white=[42; 51; 59; 69; 80; 87; 94; 111; 125; 144; 160; 169];
white_param=robustfit(mass,white)
white_linear=white_param(1)+white_param(2)*mass;
white_corr=corr(mass,white)
plot(mass,white,mass,white_linear)
