He moved with his parents to North Brookfield, Massachusetts, and attended the district school. In 1814 he entered commercial life, and in 1820 formed a partnership with Allen Newell in North Brookfield, but three years later withdrew to become the agent of the Methuen Manufacturing Company. In 1825 he formed the firm of Carleton and Walker, of Boston, with Charles G. Carleton, but in 1827 he went into business independently. He was a delegate to the 1836 Democratic National Convention. In 1839, he became president of the Boston Temperance Society, the first total abstinence association in that city, and in 1839 he advocated a continuous railway between Boston and the Mississippi River. In 1840 he retired from commercial life and went into academia. In 1842–1848 he lectured on political economy at Oberlin College, in 1853–1860 he was an examiner on political economy at Harvard, and in 1859–1869 lecturer on political economy at Amherst College. The degree of LL.D. was conferred on him by Amherst in 1867. He was a frequent contributor to periodical literature, especially on financial subjects. His principal work, Science of Wealth, a Manual of Political Economy, was published in 1866. Other works were Nature and Uses of Money and Mixed Currency and, with William B. Calhoun and Charles L. Flint, Transactions of the Agricultural Societies of Massachusetts. In 1857 he began the publication of a series of articles on political economy in Hunt's Merchant's Magazine. He was active in the anti-slavery movement, and in 1848 he was one of the founders of the Free Soil Party. Walker served in the Massachusetts House of Representatives in 1849 and 1860, in the Massachusetts State Senate in 1850, as Massachusetts Secretary of the Commonwealth 1851–1853, and in the United States House of Representatives 1862–1863, where he was elected as a Republican to fill the vacancy caused by the death of Goldsmith Bailey. In 1853, he was chosen a member of the convention for revising the state constitution, becoming the chairman of the committee on suffrage. In 1860 he was chosen a member of the electoral college of Massachusetts, and cast his ballot for Abraham Lincoln. Walker was a delegate to the first International Peace Congress in London of 1843, and he served at the Paris Congress in 1849.