{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "# Classification of Organisms\n", "Using a Digital Dichotomous Key\n", "\n", "This Juptyer Notebook will allow you to search through different organisms based on their physical characteristics using a tool known as a Dichotomous Key. Start out by going to Kernal -> Restart & Run All to begin!" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": true }, "outputs": [], "source": [ "# Import modules that contain functions we need\n", "import pandas as pd\n", "import numpy as np\n", "%matplotlib inline\n", "import matplotlib.pyplot as plt" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "# Our data is the dichotomous key table and is defined as the word 'key'.\n", "# key is set equal to the .csv file that is read by pandas.\n", "# The .csv file must be in the same directory as the program.\n", "\n", "#If the data is being pulled locally use the code that is commented out below\n", "#key = pd.read_csv(\"Classification of Organisms- Jupyter Data.csv\")\n", "#key2 = pd.read_csv(\"Classification of Organisms- Jupyter Data KEY 2.csv\")\n", "\n", "key = pd.read_csv(\"https://gist.githubusercontent.com/GoodmanSciences/f4d51945a169ef3125234c57b878e058/raw/bebeaae8038f0b418ed37c2a98b82aa9d3cc38d1/Classification%2520of%2520Organisms-Jupyter%2520Data.csv\")\n", "\n", "key2 = pd.read_csv(\"https://gist.githubusercontent.com/GoodmanSciences/4060d993635e90cdcc46fe637c92ee37/raw/d9031747855b9762b239dea07a60254eaa6051f7/Classification%2520of%2520Organisms-%2520Jupyter%2520Data%2520KEY%25202.csv\")\n", "\n", "# This sets Organism as the index instead of numbers\n", "#key = data.set_index(\"organism\")" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Pre-Questions\n", "### A Dichotomous Key is....\n", "a tool that allows scienctists to identify and classify organisms in the natural world. Based on their characterists, scienctists can narrow down species into groups such as trees, flowers, mammals, reptiles, rocks, and fish. A Dichotomous Key can help to understand how scientists have classified organisms using Bionomial Nomenclature.\n", "\n", "[Dichotomous Key Video](https://www.youtube.com/watch?v=M51AKJqx-7s)" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "# Here is a helpful image of a sample Dichotomous Key!\n", "from IPython.display import Image\n", "from IPython.core.display import HTML \n", "Image(url= 'http://biology-igcse.weebly.com/uploads/1/5/0/7/15070316/8196495_orig.gif')" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## PART 1: Sorting Organisms by One Characteristic\n", "\n", "We will be looking at the characterists of 75 unique organisms in our Dichotomous Key. The imput below will provide us with a some of the possible organisms you may discover." ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "# Animal options in Dichotomous Key\n", "# Displays all row titles as an array\n", "key.organism" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "#### Importing the Organism Characteristics/Conditions" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "# Conditions/Questions for finding the correct animal\n", "# Displays all column titles as an array\n", "key.columns" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## PART 2: Sorting Organisms by Many Characteristics\n", "\n", "These are the conditions or the characteristics in which ceratin answers are categorized for certain organisms. Each characteristic/condition has a yes/no except for the Kingdoms. Change the conditionals in the code below to change what organism(s) are displayed. For most, the only change needs to be the 'yes' or 'no'. \n", "\n", "**Capitalization matters so be careful. You also must put in only allowed answers in every condition or the code will break!**" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "key[(key['decomposer'] == 'yes')]" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "# This conditional allows us to query a column and if the data within that cell matches it will display the animal(s).\n", "#if you are unsure of what to put try making that column a comment by adding # in front of it.\n", "\n", "\n", "\n", "key[\n", "#physical characteristics\n", " (key['fur'] == 'yes') & \\\n", " (key['feathers'] == 'no') & \\\n", " (key['poisonous'] == 'no') & \\\n", " (key['scales'] == 'no') & \\\n", " (key['multicellular'] == 'yes') & \\\n", " (key['fins'] == 'no') & \\\n", " (key['wings'] == 'no') & \\\n", " (key['vertebrate'] == 'yes') & \\\n", " \n", "#environmental characteristics\n", " (key['marine'] == 'no') & \\\n", " (key['terrestrial'] == 'yes') & \\\n", " \n", "#feeding characteristics\n", " \n", " #decomposers get their food by breaking down decaying organisms\n", " (key['decomposer'] == 'no') & \\\n", " \n", " #carnivores get their food by eating animals\n", " (key['carnivore'] == 'no') & \\\n", " \n", " #herbivores get their food by eating plants\n", " (key['herbivore'] == 'yes') & \\\n", " \n", " #omnivores get their food by eating both plants and animals\n", " (key['omnivore'] == 'no') & \\\n", " \n", " #photosynthesis is the process of making food using energy from sunlight\n", " (key['photosynthesis'] == 'no') & \\\n", " \n", " #autotrophs are organisms that generate their own food inside themselves\n", " (key['autotroph'] == 'no') & \\\n", " \n", "#possible kingdoms include: animalia, plantae, fungi\n", " (key['kingdom'] == 'animalia') & \\\n", " \n", "#cell type \n", " (key['eukaryotic'] == 'yes') & \\\n", " (key['prokaryotic'] == 'no')\n", " ]" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "## Part 3: Scientific Classification of Organisms" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "#sort your organisms by their taxonomical classification\n", "\n", "# This conditional allows us to query a column and if the data within that cell matches,\n", "# it will display the corresponding animal(s)\n", "key2[(key2['kingdom'] == 'animalia')]\n", "\n" ] }, { "cell_type": "code", "execution_count": null, "metadata": { "collapsed": false }, "outputs": [], "source": [ "#Done?? Insert a image for one of the organisms you found using the dichotomous key.\n", "from IPython.display import Image\n", "from IPython.core.display import HTML \n", "Image(url= 'https://lms.mrc.ac.uk/wp-content/uploads/insert-pretty-picture-here1.jpg')" ] } ], "metadata": { "kernelspec": { "display_name": "Python [Root]", "language": "python", "name": "Python [Root]" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.5.2" } }, "nbformat": 4, "nbformat_minor": 2 }