MAke MID IR photospectrometer X-Y plot from rotary encoder +Arduino + Raspberry Pi

Hi, I was wondering it is possible to make an MID-IR photospectrometer project using a IR-sensor which does a sweep /arc of a prism and makes an X-Y Plot of wavelength versus intensity using
Raspberry Pi
IR Sensor
geared down rotary motion with encoder for ARC-SWEEP of IR-sensor?
Any Help is appreciated

Richard C

Basically the X-Y plot measures / records IR sensor output [INTENSITY]
ENCODER POSITION [which is wavelength]