Inverse gamma  This applies a brightness weighting according to the following formula, where ic = the calculated brightness value, the function returns a
percentage that is then multiplied by 255:
var c = ic/255.0;
if ( c <= 0.04045 ){
return c/12.92;
} else {
return Math.pow(((c+0.055)/(1.055)),2.4);
}

Flat  Applies no brightness weighting. 
gamma (like PS)  Approximates to the greyscale calculation formula used by
Photoshop. red_value × 0.2235, green_value × 0.7154, blue_value × 0.0611, each in turn passed through the inverse gamma formula as shown above, then the
result vi passed through a gamma formula as follows, which returns a percentage
that is then multiplied by 255:
return vi<=0.0031308 ? vi * 12.92 : 1.055*Math.pow(vi,1.0/2.4)0.055;

CIE XYZ  red_value × 0.299 + green_value × 0.587 + blue_value × 0.114 
YIQ  YIQ coefficients also known as Digital CCIR601 and suggested in the Web Accessibility Guidelines from the W3C and challenged by me (see Holes in the W3C Colour Readability Guidelines. ) red_value × 0.2125 + green_value × 0.7154 + blue_value × 0.0721 
Lightness  ½ × (max(R,G,B) + min(R,G,B)), see Puzzling Greys. 
Average  (R + G + B) ÷ 3, see Puzzling Greys. 