O'Neill, now Republic of Ireland manager, enjoyed success at Villa Park before leaving the club rather suddenly.
The then Aston Villa boss was given plenty of money to spend but Lambert has not had the same fortune.
Currently, Villa are 16th in the Premier League table, with one of the worst goal differences in the division. But West Ham boss Allardyce feels a little spending money would make that scenario somewhat different.
“He must be wondering what he is doing wrong. I think if he had as much money to spend as Martin O’Neill he would be very very happy and you would expect he wouldn’t be in this position," Allardyce told reporters.
“There was a change of financial policy at Aston Villa and when he eventually took over it was about reduction of wages rather than increase of wages.
"When you’ve had to manage that period and that level it would be the biggest learning experience as a manager that he’s every experienced."
West Ham host Lambert's men at 3pm later today.