At familysearch, searching for Lockhart in Ramsay Ontario Canada (which is in Lanark County - near Ottawa), there is a John born 1793 in Scotland, in the 1871 census. That could fit.
Using his details to search:
02, Ramsay a, North Lanark 80, Ontario, Canada
he is the only result (did the 1871 Canada only include head of household? I forget -- but that record would be viewable at Anc'y)
He is there in 1861, shown as born 1794.
In 1861 there are an Elizabeth and William Lockhart both on page 76, lines 40 and 41, so it's possible to match up household members by the records at familysearch for that census.
I don't see anyone else on the same page as John, page 1 line 9 (clicking on all the Lockharts in Ramsay Lanark Ontario Canada in 1861), so presumably he was widowed by that time.
I can't see him in 1851 at Anc'y, even just searching for John in Lanark County born in Scotland 1788-1798, and it returns nil for loc*rt born in Scotland 1785-1825.
Troy (Albany), NY, is roughly equidistant from Ottawa and Toronto, so that doesn't help us tremendously to figure out whether a young woman from Lanark County, Ontario, might be a likely candidate, unfortunately. Generally speaking, there was more traffic from the Toronto region to NY state than from the Ottawa region, I'd say.