On this probably russian website you can see a picture of Galaxy S4's PWM frequencies: http://www.ixbt.com/mobile/samsung-galaxy-s4.shtml At 100% brightness it just uses 60 Hz while at 50% it's 240 Hz. Not sure if the Value Edition has the same display. I myself use a OnePlus 3. No trouble with those 60 Hz that have a very small difference in amplitudes. But 240 Hz with strong amplitudes are killing my eyes. That's why I use only brightness 25% and up, which are 60 Hz @ low differences on the OnePlus 3. The Galaxy S4's only option might be 100%.
Maybe you still have a headache from using the screen at 50%? Then again at 100% one could get a headache easily not because of PWM but because of the insane brightness.
To narrow down the problem, make sure to disable all "overlay" apps - apps that alter brightness levels by applying an overlay. If you're asked to allow an app to draw over other apps, it's one of those overlay apps. I get eye strain and headaches by using such apps, e.g. "Lux Auto Brightness" and "Velis Auto Brightness". I'd also disable any screen enhancements if there are any in Samsung's settings.
I also noticed I quickly get eye strain from Firefox and Opera Mobile. Opera Mini and Chrome are good for me.
Not sure if parts of Samsung's software additions might cause your problem. If you want to do it, you might install CyanogenMod 13 and see if it helps. It most probably won't alter the PWM frequencies but the idea is to use an OS that's known to work (at least for me it does) until the real problem is found.
It might void your warranty though.