Is vegetable oil as good as motor oil to oil a bike?
Vegetable oils tend to "polymerize", that is become sticky and solid. Castor oil, for instance, is an excellent lubricant that was favored for racing autos and motorcycles for a long time. The reason it never became popular for regular cars was that it also built up a lot of sticky, cruddy goo. Racing engines are regularly torn down and rebuilt; no matter. Not so your sedan. The oils used in oil-based paints are usually vegetable-based as well; they tend to become quite solid after a while.
As I've noted before, lubes, especially chain lubes, seem to be a "thing" for serious cyclists. Chain lube threads on dedicated bike forums tend to go on and on and on... It's the engineering mentality at work. "Maybe I can get 100 more miles out of my chain if I concoct my own special blend!" Maybe... Chain lubes are cheap. They cost at most what, 10 bucks for a bottle sufficient for a year? As well, chains are cheap. Oh, you can spend a lot for super-deluxe items, but a good, well-made standard chain is under 20 bucks and will last most riders as long as they keep the bike if lubed and cleaned properly.
On the chain, not so much. As M. Werner says, it polymerises and turns into stick goo fairly quickly, and there's nothing you can do to stop that. So you can really only put it somewhere that it's easy to remove. Like a chain. Then you just need to use a chain cleaner on it every couple of weeks and reapply the oil. Using vege oil other places could be awful. Inside a hub gear especially, for one example.
I have one friend who tried vegetable oil on his chain, and experimented with a variety of oils. He doesn't use vege oil any more, from memory because it turned to black goo too fast. I believe that even cheap motor oil is better. I have emailed him a link, hopefully he will chime in.
Edit: he says he doesn't have anything useful to add.
Mineral oil consists of "alkanes" which have a simple chemical formula (CnH2n+2).
Fats go rancid because their molecules include relatively complicated/weak bonds.
(I'm less sure about waxes; but oil is more common, in chain lube, than wax).
I've just Googled the oil which my LBS sold me and note that it says, "Finish Line’s WET Lubricant features an Inherently Biodegradable formulation which that between 20% and 60% of the product’s base oils will degrade within 28 days."
Contrast that with another type of oil, which lasts a long time by being mineral oil.
I'm not really sure what the intent behind the question is here, but I have tried vegetable oil, and it's not great. It doesn't smell enough to concern you, but it gets gummy pretty quickly, and picks up dirt. It might be alright if you cleaned and re-applied really regularly (like every 3-4 days?), but I was too lazy to bother.
The reasons I wanted to try vege oil were basically environmental, and because I don't want to use products produced by the petroleum industry. Ok, and perhaps a little symbolism.
Anyway, a quick web search for "environmental bike lubricant" reveals http://www.green-oil.net/environment.html, which looks promising (long-chain polymers extracted from plant oil), and seems to have decent reviews. I haven't tried it yet, but will see if I can get some and try it out.
If your bike was a garage sale or dumpster find, sure, put vegetable oil on it. I do it to old kids' bikes. It works ok, and doesn't get them as greasy as motor oil or axle grease. I've seen a lawn mower that someone filled with canola oil instead of motor oil, and it ran just fine for a long time, though the oil did thicken up and stink.
FWIW there is a vegetable oil based chainsaw bar oil on the market, and I've used cheap corn oil with a little used motor oil as a bar oil for months. It works great, but smokes a little, and has to be drained from the reservoir or it will congeal some.
Some chains aren't cheap. The new "9 speed" chains are $20+, the "10 speed" chains are around $30-80, and the sure to be next 11, 12, 13 speed chains are italian top shelf stuff and $$$$$.
Since the question never actually specified which part of the bike was to be oiled, I'll point out that linseed oil (specifically boiled linseed oil) is often used as spoke prep.
In this case, it's used to lubricate the spoke threads during wheel assembly, and the fact that it dries afterwards is desirable as it acts like a threadlock to resist the nipple unscrewing.
Tri-flow now makes a soy-based chain lube: http://www.triflowlubricants.com/Tri-Flow_Superior_Soy_Lubricant_Drip.html A big ol' jug of soybean oil from the grocery store has the problems noted elsewhere.
I use Green Oil chain lube and it works just as well as dry lube/petrochemical oil/gt85 ever did. It smells much better too, like some kinda cooking oil.