is it knocking or tapping?
check your oil, low oil level will give you tapping and also old oil will too. how many miles are on the last oil change? Miatas tend to have a lot of valve noise on old oil, at least both of mine do, 94 & 95. Try some Mobil 1 15w50 next oil change.
stalling:
how old are your spark plugs?
how about the spark plug wires?
has the engine bay been power-washed recently? if yes, water can leak down into where the spark plugs sit, yes past those rubber boots. pull the boots off and dry out those cavities. hairdryer should work or they will just dry themselves within a few days.
your idle speed may be set too low, read here to adjust that
http://www.miata.net/garage/ignition.html#idle
the miata is also equipped with a device that measures the air flow intake. if there are any leaks between it and the throttlebody the onboard computer will slow down or stall the engine.
Check your air filter too, it could be totally clogged.
Could be your timing being retarded too far
If you can't figure it out, post on
http://www.miataforum.com/ part of
www.miata.net
Many .netters would be willing to help you out just cuz you share the same passion as us, a Miata. Some of us actually enjoy working on Miatas and welcome the challenge. I know I would do it, but I am in NJ.
Good Luck