1. An image forming apparatus comprising: a processor configured to: obtain an output image of a primary color and a secondary color that is formed on a recording medium based on an image having an area ratio of each toner being uniform over the recording medium; obtain spectral reflectance of the output image in a main scanning direction; obtain spectral reflectance of a primary-color solid-fill image and the recording medium stored in a memory; calculate fluctuations in area ratio of each toner of a streaked area of the output image using the spectral reflectance of the streaked area and a streak-free area of the output image; and correct an area ratio of each toner in the streaked area of image data to be output according to the fluctuations in area ratio.