State tax filing

The formula used is NY Adjusted Gross Income divided by Federal Adjusted Gross Income.

The NY number used would not be the same number as shown on your W2s as that is pre-adjustments.  The line number used is line 31 of your Form IT-203.

You can see the instructions for this line here - 

https://www.tax.ny.gov/pdf/current_forms/it/it203i.pdf (page 30)

https://www.tax.ny.gov/pdf/current_forms/it/it203_fill_in.pdf