Coder Social home page Coder Social logo

lepe / astroapi Goto Github PK

View Code? Open in Web Editor NEW

This project forked from kibo/astroapi

0.0 1.0 0.0 1.17 MB

Simple API allowing consumers to get planets and cusps positions.

License: GNU General Public License v3.0

Java 50.72% HTML 49.10% CSS 0.11% JavaScript 0.07%

astroapi's Introduction

AstroAPI

The AstroAPI is a simple API allowing consumers to get planets and cusps positions. The AstroAPI uses Swiss Ephemeris library port to Java by Thomas Mack. AstroAPI is clear and tested API over this library.

Planets:

Sun, Moon, Mercury, Venus, Mars, Jupiter, Saturn, Uranus, Neptune, Pluto, Chiron, Lilith, NNode.

House systems:

Placidus, Koch, Porphyrius, Regiomontanus, Campanus, Equal, Vehlow Equal, Whole, Axial Rotation, Horizontal, Polich/Page, Alcabitius, Gauquelin sectors, Morinus.

Coordinate systems

Geocentric, Topocentric.

Zodiac type

Tropical, Sidereal

Version: 1.0.0

Documentation

Install

  • set path to ephemeris
  • mvn clean package
  • mvn javadoc:javadoc

Example

// Topocentric, tropical, all planets.
Planet planetEphemeris = new PlanetBuilder(event)
  				.planets() 					
  				.topo(48.8555, 18.0488, 0)
  				.build();
planetEphemeris.toJSON();

// Geocentric, sidereal, Sun and Moon only.
Planet planetEphemeris = new PlanetBuilder(event)
 				.planet('Sun, Moon')
				.zodiac("Fagan Bradley")	
				.build();
planetEphemeris.toJSON();				
 // Tropical, Campanus.
 Cusp cuspEphemeris = new CuspBuilder(event)
  				.houses("Campanus") 					
  				.topo(48.8555, 18.0488, 0)
  				.build();
 cuspEphemeris.toJSON();
// Sidereal, Placidus
Cusp cuspEphemeris = new CuspBuilder(event)
  				.houses("Palcidus")
  				.topo(48.8555, 18.0488, 0)
    				.zodiac("Fagan Bradley")	
 				.build();
cuspEphemeris.toJSON();
// Tropical, the Moon in opposition with the Sun.
 Transit transit = new TransitBuilder(event)
  				.planet("Moon") 					
  				.toPlanet("Sun") 
  				.aspect(180.0)
  				.build();
 	
 System.out.println( transit.getDate() );
// Sidereal, the Moon in trine with the point 36.3° in zodiac. Backwards.
 Planet transit = new PlanetBuilder(event)
  				.planet('Moon')
  				.toPoint(36.3)
  				.aspect(120.0)
   				.zodiac("Fagan Bradley")	
   				.backwards(true)
 				.build();
 
System.out.println( transit.getDate() );

License

GNU public version 3

astroapi's People

Contributors

kibo avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.