Tansy can be used in cooking, but it should be used sparingly, because in large amounts it can cause violent reactions and even death! That being said, Rodale's Illustrated Encyclopedia of Herbs says its leaves are peppery and strong and were used in the past as a substitute for pepper when that exotic spice was unavailable.
One use for Tansy is as an insect repellant. My mother-in-law used to hang bunches of it on her back porch to keep flies away from her trash. She swore by it. And, colonial cooks rubbed Tansy into their wooden tabletops to discourage bugs. It is also supposed to repel ants and, in fact, is also known as "ant fern" since sprigs of it have been used to keep ants from raiding kitchen cabinets.
In the middle ages, it was used as a "strewing" herb. These were strong smelling herbs that were strewn on the floors. When they were trod upon, it released the oils in them which masked the human body odors that were prevalent in those days due to poor hygiene practices.
I am growing Tansy in my garden to attract beneficial insects. It is HUGE and has small yellow, button-like flowers. Here is a picture of my granddaughter standing next to it.
The flowers are not very apparent in this picture, because it has just now started to bloom. Here is a closeup of them.