Don't get too excited yet! Some given names are useful for tracing families, but there are several that are so common that they are not all that useful on their own. These include Alexander, James, John and William for males and Ann(e), Elizabeth, Isabel(la), Jean/Jane, Margaret and Mary for females.
The 'Community indexed' IGI lists 40 marriages of a Marshall to a Hay in Scotland.
Note that until the start of statutory civil registration in 1855 there was no such thing as a 'marriage certificate' and that marriage records up to 1854 seldom give the name of the bride's father, let alone that of her mother or the parents of the bridegroom.
James Marshall married Elizabeth Hay in Denny, Stirlingshire on 5 September 1831. The index also lists the name Matthew Hay - which could be one of the rare instances of a marriage record giving the name of the bride's father. The IGI lists two children:
Matthew, baptised in Denny 8 June 1834
David, baptised in Denny 20 December 1843
The 1841 census lists this family at Haggs, Denny
James, 30, Coal miner; Elizabeth, 30; Matthew, 5; Mary, 3; Robert, 1; Elisabeth Wilson, 70 ; all born in Stirlingshire
In 1851 the family were at Backrow, Denny
James, 43, Collier (i.e. his
occupation was still coal mining); Elizabeth, 43; Mathew, son, 16, Collier; Mary, 13; Robert, 10; James, 9; David, 7; John, 5; Martha, 2; Elizabeth, 1; all born in Denny
William Hay Marshall married Jean Hay in Denny on 6 April 1833
The IGI lists just three children
Robert, baptised 8 February 1846
Jean, baptised in Denny 19 March 1848
William, baptised in Kilsyth, Stirlingshire 15 July 1853
As already stated, In 1841 they too were in Haggs
William Marshall, 29, Coal miner; Jean, 29; Elisabeth,8; all born in Stirlingshire, plus what looks like three lodgers.
In 1851 they were still in Haggs
William Marshall, 39, Collier; Jean, wife, 39; Mary, daughter, 7; Robert, son, 5; all born in Denny.
So these are two entirely separate couples. The coincidence of address, surname and occupation could indicate that James Marshall and William Marshall are related, but this is not necessarily the case as Marshall is a very common surname. You would need to see the death certificates of both William (who you know died in 1868) and James to check this out.
You can look up the full transcriptions of the census at
http://www.freecen.org.uk/cgi/search.pl and you can (and should) view the original documents at
www.scotlandspeople.gov.uk at modest cost when it comes back online next week. On the same site you can view the original baptism and marriage records (and learn exactly what Elizabeth's marriage record says about Matthew Hay) and the death certificates of William and (assuming he died in Scotland) James. You may find that the baptisms of some of the children listed in the census but not indexed in the IGI are also available at Scotland's People.
You will note that the census confirms the birthplaces of both William Hay Marshall and Jean Hay as Denny.