Try replacing the injectors.
I had the same issue and replaced the ignition control module and it started up fine. I also replaced the O2 sensor.
Have you replaced the distributor cap? I have a 94 Maxima that would not start due to a cracked distributor cap. (Check for sparks under the hood when it's dark.)
You should check with a certified repair shop and have them scan it for codes. That is much cheaper than replacing parts.
Sounds like rigs or valves. Start with a compression test.
Have you checked the o2 sensor, map sensor. will cause rough running problems assuming it hasn't got a blown head gasket. does it start on six cylinders when stone cold? assuming it's a six cylinder.
check your battery or you spark plugs
try a new ignition coil
Crank and or Cam sensors may be bad. I would Buy both and try the Crank sensor first.
a good possibility is the coolant temp sensor if its not reading the correct temperature it wont be able to make the right disision. for instance if its 30 degrees and the sensor reads 60 degrees it wont give the engine enough gas to start SECOND ANSWER: I had a similar problem. It turned out to be two spark plugs were not tightened when I had the plugs replaced. I replaced all all the plugs with the OEM plugs and found that two of the Bosch plugs installed the previous time were so loose that those two cylinders were loosing compression. After installing and torqing the new OEM plugs the 4.6 runs like new and always starts easily.
odds are the sensor needs to be replaced
Symptoms of a bad crank sensor is hard starting, no starting or rough idle. If you're able to start the engine, and it runs for a few minutes or seconds and then dies out, most likely it's a bad crank position sensor. Also, there may be no spark in some of the spark plugs.
I noticed rough idle on a 2001 MGM and what seemed like transmission slip while going uphill. I replaced the spark plugs. Both problems went away.