The theory of psychohistory developed by Dr Hari Seldon in Asimov’s Foundation novels had applied only to predicting the behaviors of large populations as a whole. The analogy was where each person was like a gas particle and the theory predicted the behavior of the gas on a macroscopic scale. (Think macroeconomics.)
It could not predict behavior on small scales. (The theory’s predictions got trashed anyway when a Napoleon appeared.)