mirror of
https://github.com/AllenDowney/AstronomicalData.git
synced 2026-07-28 14:47:02 -07:00
Updating notebooks
This commit is contained in:
+21
-14
@@ -41,7 +41,7 @@
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"source": [
|
||||
"[This article in *Science* magazine](https://www.sciencemag.org/news/2018/10/streams-stars-reveal-galaxy-s-violent-history-and-perhaps-its-unseen-dark-matter) explains some of the background, including the process that led to the paper and an discussion of the scientific implications:\n",
|
||||
"[This article in *Science* magazine](https://www.sciencemag.org/news/2018/10/streams-stars-reveal-galaxy-s-violent-history-and-perhaps-its-unseen-dark-matter) explains some of the background, including the process that led to the paper and a discussion of the scientific implications:\n",
|
||||
"\n",
|
||||
"* \"The streams are particularly useful for ... galactic archaeology --- rewinding the cosmic clock to reconstruct the assembly of the Milky Way.\"\n",
|
||||
"\n",
|
||||
@@ -112,7 +112,7 @@
|
||||
"source": [
|
||||
"## Query Language\n",
|
||||
"\n",
|
||||
"In order to select data from a database, you have to compose a query, which is like a program written in a \"query language\".\n",
|
||||
"In order to select data from a database, you have to compose a query, which is a program written in a \"query language\".\n",
|
||||
"The query language we'll use is ADQL, which stands for \"Astronomical Data Query Language\".\n",
|
||||
"\n",
|
||||
"ADQL is a dialect of [SQL](https://en.wikipedia.org/wiki/SQL) (Structured Query Language), which is by far the most commonly used query language. Almost everything you will learn about ADQL also works in SQL.\n",
|
||||
@@ -123,27 +123,25 @@
|
||||
},
|
||||
{
|
||||
"cell_type": "markdown",
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"remove-cell"
|
||||
]
|
||||
},
|
||||
"source": [
|
||||
"## Installing libraries\n",
|
||||
"\n",
|
||||
"The library we'll use to get Gaia data is [Astroquery](https://astroquery.readthedocs.io/en/latest/).\n",
|
||||
"\n",
|
||||
"If you are running this notebook on Colab, you can run the following cell to install Astroquery and the other libraries we'll use.\n",
|
||||
"\n",
|
||||
"If you are running this notebook on your own computer, you might have to install these libraries yourself. \n",
|
||||
"\n",
|
||||
"If you are using this notebook as part of a Carpentries workshop, you should have received setup instructions.\n",
|
||||
"\n",
|
||||
"TODO: Add a link to the instructions.\n"
|
||||
"If you are running this notebook on your own computer, you might have to install these libraries yourself. See the instructions in the preface."
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 1,
|
||||
"execution_count": 8,
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
"remove-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
@@ -163,6 +161,8 @@
|
||||
"source": [
|
||||
"## Connecting to Gaia\n",
|
||||
"\n",
|
||||
"The library we'll use to get Gaia data is [Astroquery](https://astroquery.readthedocs.io/en/latest/).\n",
|
||||
"\n",
|
||||
"Astroquery provides `Gaia`, which is an [object that represents a connection to the Gaia database](https://astroquery.readthedocs.io/en/latest/gaia/gaia.html).\n",
|
||||
"\n",
|
||||
"We can connect to the Gaia database like this:"
|
||||
@@ -446,7 +446,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
@@ -613,8 +617,10 @@
|
||||
"cell_type": "code",
|
||||
"execution_count": 8,
|
||||
"metadata": {
|
||||
"scrolled": true,
|
||||
"tags": [
|
||||
"remove-cell"
|
||||
"hide-cell",
|
||||
"remove-output"
|
||||
]
|
||||
},
|
||||
"outputs": [
|
||||
@@ -1672,6 +1678,7 @@
|
||||
}
|
||||
],
|
||||
"metadata": {
|
||||
"celltoolbar": "Tags",
|
||||
"kernelspec": {
|
||||
"display_name": "Python 3",
|
||||
"language": "python",
|
||||
|
||||
+5
-1
@@ -1739,7 +1739,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 127,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
|
||||
+10
-2
@@ -677,7 +677,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 21,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
@@ -720,7 +724,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 23,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [
|
||||
{
|
||||
"name": "stdout",
|
||||
|
||||
+25
-5
@@ -939,7 +939,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 24,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
@@ -1012,7 +1016,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 26,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
@@ -1025,7 +1033,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 27,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
@@ -1038,7 +1050,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 28,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
@@ -1053,7 +1069,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 29,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
|
||||
+15
-3
@@ -239,7 +239,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 6,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
@@ -298,7 +302,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 7,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
@@ -978,7 +986,11 @@
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": 28,
|
||||
"metadata": {},
|
||||
"metadata": {
|
||||
"tags": [
|
||||
"hide-cell"
|
||||
]
|
||||
},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Solution\n",
|
||||
|
||||
Reference in New Issue
Block a user