It is immensely difficult. This was fictionally explored in a Tom Cruise movie where future crime was detected with a device and psychics to arrest people before the crime was commited.
You can't arrest everyone who acts wierd but if the individual has a cache of weapons what is the harm in taking a second look?
One harm was the seige at Waco. Ruby Ridge The fire bombing by Philly police that killed a black community SWAT team murders resulting from a wrong address etc etc
under react vs over react
its a tough nut
One thing I could say is if you live by the gun you might die by the gun.