Project

astronomy

0.0
No commit activity in last 3 years
No release in over 3 years
Search or browse the names, descriptions and image URLs for various categories including: Asterism, Celestial Object, Star, Planet, Star System, Galaxy, Moon, Comet, Asteroid, Constellation, Nebula, Astronomical Discovery, Cluster and Meteor Shower. Also provides links to the full Freebase JSON data.
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 1.7
~> 10.0
~> 3.0
 Project Readme

Astronomy

Search or browse the names, descriptions and image URLs for various categories of celestial phenomena including:

  • Asterisms
  • Celestial Objects
  • Stars
  • Planets
  • Star Systems
  • Galaxies
  • Moons
  • Comets
  • Asteroids
  • Constellations
  • Nebulae
  • Astronomical Discoveries
  • Clusters
  • Meteor Showers

Data source: Freebase

For example, here is the entry on the Big Dipper:

{
             "name" => "Big Dipper",
      "description" => "The Big Dipper, also known as the Plough, is an asterism of seven stars recognized as a distinct grouping in many cultures. These stars are the brightest of the formal constellation Ursa Major; six of them are second magnitude stars, while only Megrez is of third magnitude. The North Star, the current northern pole star on Earth, can be located by extending an imaginary line from Merak through Dubhe. Polaris is part of the \"Little Dipper\", Ursa Minor.",
           "images" => [
        [0] "https://usercontent.googleapis.com/freebase/v1/image/m/02dd6yz",
        [1] "https://usercontent.googleapis.com/freebase/v1/image/m/04shvsk"
    ],
    "detailed_info" => "https://www.googleapis.com/freebase/v1/topic/m/09csbt"
}

Search over 600K of user curated data.

Installation

Add this line to your application's Gemfile:

gem 'astronomy'

And then execute:

$ bundle

Or install it yourself as:

$ gem install astronomy

Usage

Get all of the data as a hash:

info = Astronomy::Information.new
info.data

Get a full list of categories:

info = Astronomy::Information.new
info.categories

Get a list of topics from a given category:

info = Astronomy::Information.new
info.topics 'Comet'

Search both names and descriptions:

info = Astronomy::Information.new
info.search 'moon'

Contributing

  1. Fork it ( https://github.com/[my-github-username]/astronomy/fork )
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create a new Pull Request