Heredia, Nicolás, 1855-1901