Star Wars API Reader

Read data from the Star Wars API (SWAPI) --


Updated 6 Dec 2019

View License

Editor's Note: This file was selected as MATLAB Central Pick of the Week

The Star Wars API (SWAPI) provides open data to explore and analyze the universe: --
You can read this data into MATLAB with the function swapiread. The function imports the data by record or by collection and converts the data to a MATLAB-friendly format for analysis.

Cite As

Heather Gorr, PhD (2023). Star Wars API Reader (, MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2017a
Compatible with any release
Platform Compatibility
Windows macOS Linux

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!
Version Published Release Notes

Updated graph example

Updated graph example to Live Script

Added graph example, helper function, and tests

Updated example to show another character's height.