Question: What year did the country where Antonio Medellín Varela's party located gain independence from Spain?

full_context: Document 1: David Lara Compeán: David Lara Compeán (born 11 September 1965) is a Mexican politician from the National Action Party. From 2006 to 2009 he served as Deputy of the LX Legislature of the Mexican Congress representing San Luis Potosí.
Document 2: Elia Hernández Núñez: Elia Hernández Núñez (born 20 June 1962) is a Mexican politician from the National Action Party. From 2006 to 2009 she served as Deputy of the LX Legislature of the Mexican Congress representing Guanajuato.
Document 3: Tucson, Arizona: Arizona, south of the Gila River was legally bought from Mexico in the Gadsden Purchase on June 8, 1854. Tucson became a part of the United States of America, although the American military did not formally take over control until March 1856. In 1857 Tucson became a stage station on the San Antonio-San Diego Mail Line and in 1858 became 3rd division headquarters of the Butterfield Overland Mail until the line shut down in March 1861. The Overland Mail Corporation attempted to continue running, however following the Bascom Affair, devastating Apache attacks on the stations and coaches ended operations in August 1861.[citation needed]
Document 4: Chihuahua (state): and Camargo. In 1631 Juan Rangel de Biezma discovered a rich vein of silver, and subsequently established San Jose del Parral near the site. Parral remained an important economic and cultural center for the next 300 years. On December 8, 1659 Fray García de San Francisco founded the mission of Nuestra Señora de Guadalupe de Mansos del Paso del Río del Norte and founded the town El Paso Del Norte (present day Ciudad Juárez) in 1667. The Spanish society that developed in the region replaced the sparse population of indigenous peoples. The absence of servants and workers forged the spirit of northern people as self-dependent, creative people that defended their European heritage. In 1680 settlers from Santa Fe, New Mexico sought refuge in El Paso Del Norte for twelve years after fleeing the attacks from Pueblo tribes, but returned to Santa Fe in 1692 after Diego de Vargas recaptured the city and vicinity. In 1709, Antonio de Deza y Ulloa founded the state capital Chihuahua City; shortly after, the city became the headquarters for the regional mining offices of the Spanish crown known as Real de Minas de San Francisco de Cuéllar in honor of the Viceroy of New Spain, Francisco Fernández de la Cueva Enríquez, Duke of Alburquerque and the Marquee of Cuéllar..
Document 5: Dora Martínez Valero: Dora Alicia Martínez Valero (born 3 January 1976) is a Mexican politician from the National Action Party. From 2006 to 2009 she served as Deputy of the LX Legislature of the Mexican Congress representing Coahuila.
Document 6: History of San Antonio: The ``Villa de Bejar ''was founded by Spanish explorers on May 5th, 1718, by then Governor Martin Alarcon, at the headwaters of the San Pedro Creek. The mission San Antonio de Valero was established on the east bank of the creek and a presidio was 3 / 4 of a league downstream. Development of the Spanish colonial city followed. A trading post was also established near the presidio and the town developed as the capital of Tejas, a province of colonial Spain. It was the northernmost settlement associated with the Hispanic culture of the Valley of Mexico.
Document 7: Silvia Degante Romero: Silvia Emilia Degante Romero (born 6 August 1969) is a Mexican politician from the National Action Party. From 2006 to 2009 she served as Deputy of the LX Legislature of the Mexican Congress representing San Luis Potosí.
Document 8: Antonio Medellín Varela: Antonio Medellín Varela (born 10 July 1957) is a Mexican politician from the National Action Party. From 2006 to 2009 he served as Deputy of the LX Legislature of the Mexican Congress representing San Luis Potosí.
Document 9: Leticia Sosa: In 2006 she was elected to serve in the Senate of Mexico for a six-year term. She left the Senate to run for Governor of the state of Colima. In 2009 She was designated the PAN candidate for the 2009 Colima state election. Sosa was defeated by the PRI candidate.
Document 10: Luisa María Calderón: Luisa María de Guadalupe Calderón Hinojosa (born October 23, 1956 in Mexico City) is a Mexican politician affiliated with the National Action Party who served in the Senate of Mexico from 2000 until September 2006. She is currently senator-elect as a PAN proportional representative. Her term in the senate began in late 2012 and will continue through 2018. "Cocoa" (her nickname) is known as a champion for women and minority rights throughout Mexico.
Document 11: Rosa Rosales: Rosa Rosales is an American political activist. She served as the 45th national president of the League of United Latin American Citizens, the largest and oldest Hispanic civil rights organization in the United States, from 2002–2010. Rosales advocates for Hispanics across the country on issues of education, health, housing, civil rights, and many other issues affecting Hispanics.
Document 12: Tucson, Arizona: Jesuit missionary Eusebio Francisco Kino visited the Santa Cruz River valley in 1692, and founded the Mission San Xavier del Bac in 1700 about 7 mi (11 km) upstream from the site of the settlement of Tucson. A separate Convento settlement was founded downstream along the Santa Cruz River, near the base of what is now "A" mountain. Hugo O'Conor, the founding father of the city of Tucson, Arizona authorized the construction of a military fort in that location, Presidio San Agustín del Tucsón, on August 20, 1775 (near the present downtown Pima County Courthouse). During the Spanish period of the presidio, attacks such as the Second Battle of Tucson were repeatedly mounted by Apaches. Eventually the town came to be called "Tucson" and became a part of Sonora after Mexico gained independence from Spain in 1821.
Document 13: Beatriz Paredes Rangel: Beatriz Elena Paredes Rangel (born 18 August 1953) is a Mexican politician who served as president of the Institutional Revolutionary Party (PRI). She was the first woman to serve as Governor of Tlaxcala and the second woman to serve as a state governor in Mexican history.
Document 14: Chihuahua (state): In 1562 Francisco de Ibarra headed a personal expedition in search of the mythical cities of Cibola and Quivira; he traveled through the present-day state of Chihuahua. Francisco de Ibarra is thought to have been the first European to see the ruins of Paquime. In 1564 Rodrigo de Río de Loza, a lieutenant under Francisco de Ibarra, stayed behind after the expedition and found gold at the foot of the mountains of the Sierra Madre Occidental; he founded the first Spanish city in the region, Santa Barbara in 1567 by bringing 400 European families to the settlement. A few years later in 1569 Franciscan missionaries led by Fray Agustín Rodríguez from the coast of Sinaloa and the state of Durango founded the first mission in the state in Valle de San Bartolomé (present-day Valle de Allende). Fray Agustín Rodríguez evangelized the native population until 1581. Between 1586 and 1588 a epidemic caused a temporary exodus of the small population in the territory of Nueva Vizcaya.
Document 15: Miguel Martínez Peñaloza: Miguel Martínez Peñaloza (born 12 August 1977) is a Mexican politician from the National Action Party. From 2009 to 2012 he served as Deputy of the LXI Legislature of the Mexican Congress representing Querétaro.
ground_truth: 1821
sub_queries: Antonio Medellín Varela >> member of political party Answer: National Action Party
National Action Party >> country Answer: Mexico
What year did Mexico gain independence from Spain? Answer: 1821