I am working on a school project that includes both my raspberry pi and aruduino, I have made a temperature script that allows me to monitor the pi's current temperature and I am wondering if I can read this output from my arduino in order to control a fan's speed.
You could also use serial communication. If you have to use the Arduino, then Dat Ha is right, PWM is the easiest.
How to read raspberry pi temperature from script on an Arduino to control fan