Menu

Home

Giovanni Lo Magno
Attachments
logotype.png (13279 bytes)

Introduction

SGraph is a web application that interacts with Stata for creating graphs. Its main purpose is to demonstrate how to exploit SWire for creating web applications that communicate with Stata. Thus it cannot be intended as an application for professional usage. Developers may find useful to download the source code for studying and inspirational purposes.
SGraph is an open source project and you can download the source code or try the app on-line here: http://sgraph-with-swire.sourceforge.net/
The source project is hosted in GitHub: https://github.com/lomagno/sgraph
Releases of SGraph are also available on SourceForge

Getting started for the already working web application

You can use SGraph from the following website:
https://sgraph-with-swire.sourceforge.io/

These are the instructions for getting started with SGraph:

  • Download SWire
  • Install SWire on Stata (see SWire documentation)
  • Start SWire in Stata in HTTP mode: swire start
  • Open http://localhost:50000/test to check if the SWire HTTP server is running in HTTP mode on port 50000
  • Use SGraph: click on Line chart or 3D scatter

Getting started for the source code

If you are a developer, you may desire to download the source code and start SGraph. In that case you can use git to retrive the source code:

git clone https://github.com/lomagno/sgraph.git

You need Node and npm. The latter is usually installed together with Node.
Check is npm is available in your system by typing this from the command prompt:

npm --version

Then enter the source folder:

cd sgraph/src

Install the required npm packages:

npm install

Start the webserver for serving the SGraph web application:

npm start

Check if the SGraph web application is working at http://localhost:4200/
Then follow the instructions on the SGraph homepage.

Getting started for the release

You can download a release of SGraph from here.
Uncompress the folder and serve it by using a webserver like Apache or others.
SGraph is a single-page application written in Angular. Thus you need an appropriate configuration of the web server. For example you may need to configure URL rewriting in Apache (see this documentation).


Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.