JUST RELEASED! Twilio “Geo-text” Plug-in (a PHP Uber-style Geotracker Add-On)

Check out my latest script – Twilio “Geo-text” Plug-In (a PHP Uber-style Geotracker Add-On) – click here at codecanyon.net!

WHAT IS “GEO-TEXTING”?

(def) “Geo-texting” – (verb) is the act of inviting people, via text, to share their location realtime with each other on a private geomap…uberstyle. Anyone with a smartphone and can text to the geo-text phone number can play dispatcher and invite people to share a geomap. To set up your own geo-text your own environment, you’ll need to host this plug-in, my latest script PHP Uber-style Geotracking and Twilio’s SMS “texting” services (www.twilio.com). You can try it out in my demo environment here. Just text commands (below) to 415-360-0886 – FREE!.

WHAT DOES THIS TWILIO “GEO-TEXT” PLUG-IN DO?
This Twilio “Geo-text” plug-in is an add-on to my PHP Uber-style Geotracking script that allows anyone with access to your Twilio phone number to invite people via text to share their location with others uber-style on a private geomap. In addition the script features dispatcher functionality not found in the original geotracking script. This functionality includes managing multiple geomaps, adding/deleting geotrackees, renaming maps and geotrackees, pinging geotrackees to update their location, all from a smartphone using SMS texting.

The script is super easy to install – just unzip contents (3 files) into the /php/sms folder of your original PHP Uber-style Geotracking installation. This requires a Twilio account to send and process SMS texts. Configuration instructions to link your Twilio phone number to this plug-in appear below.

NOTE: THIS SCRIPT IS AN ADD-ON AND REQUIRES THE PURCHASE OF MY PHP UBER-STYLE GEOTRACKING SCRIPT. THIS ALSO REQUIRES SIGNING UP FOR A PAID TWILIO ACCOUNT.

This script includes PHP code that CAN BE USED BY PHP DEVELOPERS AS A TEMPLATE for using SMS TEXTING (using Twilio) as the user interface for their software/web applications. For PHP developers who have not explored SMS texting as a user interface for your software (as I’ve done here), it is worth exploring. Texting is something everyone knows how to do (young, old and in between) and cuts learning curve of using your software. (see “Overview of PHP Code” section below for how code is structured).

QUICK DEMO/START
Using the plug-in is as easy as texting a list of geotrackees to the script’s twilio phone number (or for demo – 415-360-0886). Click on “Live Demo” link above for more detailed instructions.

  1. Install script/plug-in. For demo, text to 415-360-0886.
  2. Simply “text” a space or comma separated list of geotrackee email addresses or smart phone numbers to invite to a private geomap. The script will text you an invitation link (it automatically includes map owner as a geotrackee in every map. It will also text you confirmation which geotrackees were invited and which ones didn’t (didn’t pass validation).
  3. To add more geotrackees, continue to text emaill address and phone numbers to the plug-in phone number in step 1.

OTHER DISPATCHER FEATURES Here is the list of all the dispatcher features built into this script that can be executed by texting commands to your Twilio phone number on your smartphone. Click HERE for the How To Guide.

  • LIST ALL YOUR MAPS – Text “list-maps” or “lm” to the twilio number to get a numbered list of maps you own.
  • ADD A NEW MAP – Text “new-map” or “nm” to the twilio number
  • SWITCH ACTIVE MAP – Text “switch-map” or “sm” and then the map number (from “list-maps” list) to the twilio number (e.g. “sm 3”)
  • RENAME MAP – Give your map a friendlier name. Text “rename-map” or “rm”, followed by the map number and then the friendly name you want to give the map. (e.g. “rm 2 My Test Map”)
  • DELETING A MAP – Text “delete-map” or “dm” and then the map number you want to delete followed by the map number you want to delete.
  • ADDING A GEOTRACKEE – Text “add-geotrackee” or “ag” and then a comma or space separated list of geotrackee emails and phone numbers. This is optional, you can just text new emails and phone numbers. (e.g. “ag new1@dataninja.biz new2@dataninja.biz 4153333333”)
  • LIST ALL GEOTRACKEES OF ACTIVE MAP – Text “list-geotrackees” or “lg” to get a numbered list of geotrackees in the active map. (e.g. “ag new1@dataninja.biz new2@dataninja.biz 4153333333”)
  • DELETING A GEOTRACKEE – Text “delete-geotrackee” or “dg” and the geotrackee’s number from “list-geotrackee” list. (e.g. “dg 2”)
  • RENAME A GEOTRACKEE – Text “rename-geotrackee” or “rg”, the geotrackee’s number from “list-geotrackee” list and the geotrackee’s nickname. (e.g. “rg 2 Lucky Louie”)
  • PING ALL THE GEOTRACKEES IN THE ACTIVE MAP – Text “ping-geotrackee” or “pg”, then the word “all”. (e.g. “pg all”)
  • PING AN INDIVIDUAL GEOTRACKEE IN THE ACTIVE MAP – Text “ping-geotrackee” or “pg”, then the geotrackee’s number you want to ping. (e.g. “pg 3”)
  • GETTING HELP – Text “help-me” or “?” to clear all the maps and geotrackees and reset.
  • RESETTING – Text “clear-all” or “ca” to clear all the maps and geotrackees and reset.

HOW DO I INSTALL THIS PLUG-IN?

    1. If you have not done so, purchase the “PHP Uber-style Geotracker” script from codecanyon.net
    2. If you have not done so, install the script (see ‘Installation Instructions’ section in the script’s documentation)
    3. Purchase this plug-in- Twilio “Geo-Text” Plug-In
    4. Unzip the contents of the zip file into the /php/sms/ folder in your installation from step 1 and 2 (http:///php/sms/)
    5. Go to Twilio.com and sign up for your account (sign up for the SMS product – make sure you purchase a twilio phone number for your users to text to)
    6. Click on ‘Dashboard’ link to display Console Dashboard.
    7. Click on ‘Programmable SMS’ link under the All Twilio Products section on Console Dashboard.
    8. Click on ‘Messaging Services’ link on the Programmable SMS Dashbaord page
    9. Click on ‘+’ sign on the Messaging Services page
    10. Enter ‘geotracker’ as the friendly name and ‘Notifications, 2-Way’ as the use case
    11. Check the ‘Process Inbound Messages’ check box and enter https:///php/sms/receive.php and save Configure page

LIST OF GEOTEXT COMMANDS
See table below for list of commands. Examples below are “text” commands that are sent to the Twilio phone number you set up during installation (or use the demo phone number: 415-360-0886).

LIST OF COMMANDS DESCRIPTION
help-me or hm get help or list of commands
text: “help-me”
clear-all or ca clear all my maps and geotrackees
text: “clear-all” or “ca”
new-map or nm create new map
text: “new-map” or “nm”
list-maps or lm list all my maps
text: “list-maps” or “lm”
rename-map or rm rename existing map
text: “rm 2 My Map”
switch-map or sm switch active map
text: “switch-map 3”
delete-map or dm text: “delete-map 2”
add-geotrackees or ag add geotrackees to the active map (default)
text: “ag newuser1@dataninja.biz 4154444444”
list-geotrackees or lg get list of geotrackees in active map
text: “list-geotrackees”
delete-geotrackee or dg delete geotrackee
text: “dg 4”
rename-geotrackee or rg create nickname for a geotrackee
text: “rename-geotrackee 2 Cool Dude”
ping-geotrackees or pg ping all geotrackee to update location
text: “pg 1,2,3” or “pg all”
or simply type in a comma separated (“,”) list of email addresses and phone numbers directly to invite people to an active geotracking map

OVERVIEW OF PHP CODE
With this script comes a “template” PHP class that can be used as a starting point for PHP developers to create other conversational Twilio SMS applications. See below documentation of this PHP class. The code can be found in the twilioGeotextClass.php file.

CLASS SYNOPSIS

class twilioGeotext {

// Properties
private $twilioFrom; // phone number of “texter”
private $twilioBody; // body of the text
private $twilioAccountSid; // Twilio Account Sid
private $twilioAuthToken; // Twilio Auth Token
private $twilioPhoneNumber; // Twilio Phone Number
private $sessionActiveMap; // mapkey for current active map
private $db; // handle to database db
private $urlRoot; // url of script
private $background; // background color of geotrackee icon
private $letter; // assigned geotrackee letter
private $headers; // email headers<

// Methods
public function getTwilioFrom()
public function setTwilioFrom($twilioFrom)
public function getTwilioBody()
public function setTwilioBody($twilioBody)
public function getUrlRoot()
public function setUrlRoot($urlRoot)
public function getLetter()
public function setLetter($letter)
public function getHeaders()
public function setHeaders($headers)
public function getBackground()
public function setBackground($background)
public function getTwilioAccountSid()
public function setTwilioAccountSid($twilioAccountSid)
public function getTwilioAuthToken()
public function setTwilioAuthToken($twilioAuthToken)
public function getTwilioPhoneNumber()
public function setTwilioPhoneNumber($twilioPhoneNumber)
public function getSessionActiveMap()
public function setSessionActiveMap($sessionActiveMap)
public function getDb()
public function setDb($db)
public function getGeotrackeeCount() // get geotrackee count
public function getGeotrackeeTable() // assemble geotrackee table for email
public function generateRandomKey($length = 10) // generate random key
public function validatePhone($phoneNumber)
public function getMode() // get current mode of operation
public function getArg($argNo) // get n-th token from command (text body)
public function getMapkey($arg) // get mapkey of active map
public function getMapname($arg) // get mapname of active map
public function getMapCreated($arg) // get created date of active map
public function sendSms($to, $msg) // send sms back to “texter”
public function getActiveMap() // get active map info
public function doHelpMe() // do “help-me” command
public function doListMaps() // do “list-maps” command
public function doClearAll() // do “clear-all” command
public function doActiveMap() // do “active-map” command
public function doSwitchMap() // do “switch-map” command
public function doDeleteMap() // do “delete-map” command
public function doAddMap() // do “add-map” command
public function doRenameMap() // do “rename-map” command
public function doListGeotrackees() // do “list-geotrackees” command
public function doDeleteGeotrackee() // do “delete-geotrackee” command
public function doAddGeotrackees() // do “add-geotrackee” command
public function doPingGeotrackee() // do “ping-geotrackee” command
}

FUTURE IMPROVEMENTS – FROM THE NINJA
Not sure if there is much more to add to this script. I may want to
add some geotrackee viewing restrictions so that you can differentiate
between geotrackee’s that can see everyone’s location, with
geotrackees that can only see their own and also hiding owner’s
location.

I do plan to create a dispatcher module that uses a regular desktop user interface for serious dispatching. But not sure of the timing of this. It will probably leverage my other scripts including PHP Dashboards, etc. Let me know what you think by commenting on this script.

-Data Ninja

AUTHOR’S NOTE ON SCRIPT: see blog post – Twilio “Geo-Text” Plug-In
DOCUMENTATION: – How to Geotext (Guide)

REMINDER ON EXTENDED LICENSES: Just a friendly reminder that there are two different license levels at codecanyon.net. The regular license is for single FREE user use. If you have multiple clients or charging clients for functionality from this script, then an extended license is the appropriate level. It’s only fair as I do spend a lot of time tuning these scripts. And more sales/revenues means I can code more features and it has come to my attention that many purchasers are using my script for commercial (for pay) purposes with just the regular license. Thanks for you support. Click for more details – Regular vs. Extended License Comparison

SYSTEM REQUIREMENTS

    • Any browser that supports HTML5/Javascript, jQuery (2.1.4). Tested with Chrome Version 49.0.2623.110 (64-bit), Safari Version 5.1.7 (7534.57.2), Internet Explorer 11.0.9600.18230, Firefox 5.0.2
    • A PHP/MySQL supported webserver is required for jsfiddle features (preview, share, save) and render script options #3 and #4 – click here for phpinfo for PHP/MySQL versions and configuration options of the server serving up the demo. IMPORTANT: make sure to compare with phpinfo of your installation. Many PHP/MySQL errors stem from configuration options of customer php server instances.
    • You will need a PAID Twilio account and phone number

(See installation instructions on this page to see how to sign up and install)

VERSION HISTORY – Twilio “Geo-text” Plug-In

  • VERSION 1.0 (10/02/2017) – Initial launch version
    1. Twilio SMS texting user interface for the PHP Uber-style Geotracker script.
    2. Dispatcher features not found in the original geotracker script. See ”List of Text Commands’ section on this page for the list of features included in this initial version.

My Other Scripts at Codecanyon:

– (BRAND NEW!!!) PHP Daytrader’s Candlestick Pattern Hunter
– PHP Uber-style GeoTracker
– PHP Dashboard v4.0 Collaborative Social Dashboards
– PHP Dashboard v2.7 – Responsive Carousels/D3js/Highcharts/Highmaps/MySQL
– PHP Dashboard v3.0 – For Mobile Devices
– HTML5 Cloud Dashboard Designer
– HTML5 Streetmaps
– PHP Streetmaps

OTHER LINKS

Regards,
Ninja
my email: dataninja.at.codecanyon@gmail.com
my codecanyon portfolio: click here

Advertisements

Just Released! PHP Daytrader’s Candlestick Pattern Hunter

Check out my latest script – PHP Daytrader’s Candlestick Pattern Hunter – available NOW at codecanyon.net! Click here!

What does an analytics app look like? How do you visualize or productize an algorithm? This is a question many of a new generation of companies focusing on selling analytics, insights, etc. are asking themselves. (even IBM doesn’t know and resorts to a talking box in their “Watson” commercials

This script is my attempt to create a template for developing applications and productizing analytics. In this case I apply a known stock daytrader’s “analytic” called candlestick pattern recognition. But this template can be applied to any analytic. Read more below (and in my Author’s Note blog post)…

– Data Ninja 9/9/2017

WHAT IS THE PHP DAYTRADER’S CANDLESTICK PATTERN HUNTER SCRIPT?
The PHP Daytrader’s Candlestick Pattern script is a “powerful” PHP / jQuery / Javascript script takes a FREE near-real time stock quote feed (from Tradier.com) to build a “live” full featured Highstock Combination chart (see Highsoft) that uses the candlestick chart to show your stocks’ “price action” NEAR REAL TIME in a responsive webpage that can be monitored in a desktop, laptop, tablet or mobile computer/phone.

Candlestick charts are generated every minute (5 or 15 mins – delayed quotes) for any stock in the NYSE, Nasdaq and any others found in the following list of exchanges (click here for all the exchanges Tradier.com supports). In addition to displaying a stock’s price action, this script also hunts for the most common candlestick patterns and flags them in the chart, for daytraders to use to forecast behavior (bullish, bearish, neutral) of all the stock’s in their portfolio. This script is configurable so that daytraders can also define their very own patterns to monitor for also!

WHAT ARE CANDLESTICK CHARTS AND PATTERNS? The candlestick techniques stock daytraders use today originated in the style of technical charting used by the Japanese for over 100 years before the West developed the bar and point-and-figure analysis systems. In the 1700s, a Japanese man named Homma, a trader in the futures market, discovered that, although there was a link between price and the supply and demand of rice, the markets were strongly influenced by the emotions of traders. He understood that when emotions played into the equation, a vast difference between the value and the price of rice occurred. This difference between the value and the price is as applicable to stocks today as it was to rice in Japan centuries ago. The principles established by Homma are the basis for the candlestick chart analysis, which is used to measure market emotions surrounding a stock.

Compared to traditional bar charts, many traders consider candlestick charts more visually appealing and easier to interpret. Each candlestick provides an easy-to-decipher picture of price action. Immediately a trader can compare the relationship between the open and close as well as the high and low. The relationship between the open and close is considered vital information and forms the essence of candlesticks.

Green (bullish) candlesticks, where the close is greater than the open, indicate buying pressure. Red (bearish) candlesticks, where the close is less than the open, indicate selling pressure.

Candlestick patterns are a series of consecutive candlesticks that can be used to forecast future behavior of a stock – uptrend, downtrend, reversal, breakaways, consolidations, etc. See next section for more details.

WHICH PATTERNS WILL THIS SCRIPT HUNT FOR “OUT OF THE BOX”?

This script hunts for known candlestick patterns that are used by traders to predict the behavior of the stock. The following is the list of these patterns:

 DOJI (neutral) – Dojis form when a security\’s open and close are virtually equal. The length of the upper and lower shadows can vary, and the resulting candlestick looks like, either, a cross, inverted cross, or plus sign. Doji convey a sense of indecision or tug-of-war between buyers and sellers. Prices move above and below the opening level during the session, but close at or near the opening level.

 DRAGONFLY DOJI (bullish) – A Doji where the open and close price are at the high of the day. Like other Doji patterns, this one normally appears at market turning points.

 GRAVESTONE DOJI (bearish) – A doji line that develops when the Doji is at, or very near, the low of the day.

 HAMMER (bullish) – A hammer is a price pattern in candlestick charting that occurs when a security trades significantly lower than its opening, but rallies later in the day to close either above opening price. This pattern forms a hammer-shaped candlestick, in which the body is at least half the size of the tail or wick. It\’s is to referred to as a hammer, when this pattern occurs after a downtrend and a hanging man after a uptrend.

 GRAVESTONE DOJI (bearish) – A doji line that develops when the Doji is at, or very near, the low of the day.

 HANGING MAN (bearish) – A hanging man is a bearish candlestick pattern that forms at the end of an uptrend. It is created when there is a significant sell-off near the market open, but buyers are able to push this stock back up so that it closes near (but below) the opening price. Generally, the large sell-off is seen as an early indication that the bulls (buyers) are losing control and demand for the asset is waning.

 PIERCING PATTERN (bullish) – A technical trading signal that is marked by a closing down day with a good-sized trading range, followed by a trading gap (drop) lower the following day that covers at least half of the upward length of the previous day\’s real body (the range between the opening and closing prices), and then closes up for the day. A piercing pattern often signals the end of a small to moderate downward trend.

 DARK CLOUD (bearish) – A technical trading signal that is marked by a closing up day with a good-sized trading range, followed by a trading gap (rise) higher the following day that covers at least half of the downward length of the previous day\’s real body (the range between the opening and closing prices), and then closes down for the day. A piercing pattern often signals the end of a small to moderate upward trend.

 BEARISH HARAMI (bearish) – A bearish Harami is a trend indicated by a large green candlestick followed by a much smaller red candlestick with a that body is located within the vertical range of the larger geen candle body. Such a pattern is an indication that the previous upward trend is coming to an end.

 BULLISH HARAMI (bullish) – A bullish Harami is a trend indicated by a large red candlestick followed by a much smaller green candlestick with a that body is located within the vertical range of the larger red candle body. Such a pattern is an indication that the previous downward trend is coming to an end.

 BULLISH ENGULFING (bullish) – A bullish engulfing pattern is a chart pattern that forms when a small red candlestick is followed by a large green candlestick that completely eclipses or engulfs the previous candlestick. The shadows or tails of the small candlestick are short, which enables the body of the large candlestick to cover the entire candlestick from the previous cycle. Such a pattern is an indication that the previous downward trend is coming to an end.

 BEARISH ENGULFING (bullish) – A bearish engulfing pattern is a chart pattern that forms when a small green candlestick is followed by a large red candlestick that completely eclipses or engulfs the previous candlestick. The shadows or tails of the small candlestick are short, which enables the body of the large candlestick to cover the entire candlestick from the previous cycle. Such a pattern is an indication that the previous downward trend is coming to an end.

 INVERTED HAMMER (bullish) – A doji line that develops when the Doji is at, or very near, the low of the day.A doji line that develops when the Doji is at, or very near, the low of the day.A doji line that develops when the Doji is at, or very near, the low of the day. A doji line that develops when the Doji is at, or very near, the low of the day. When this pattern occurs during a downtrend, it is refered to as an inverted hammer, a bullish signal.

 SHOOTING STAR – A doji line that develops when the Doji is at, or very near, the low of the day.A doji line that develops when the Doji is at, or very near, the low of the day.A doji line that develops when the Doji is at, or very near, the low of the day. A doji line that develops when the Doji is at, or very near, the low of the day. When this pattern occurs during a downtrend, it is refered to as an shooting star, a bearish signal.

 MORNING STAR (bullish) – A morning star is a bearish candlestick pattern consisting of three candles that have demonstrated the following characteristics: the first bar is a large red candlestick located within an downtrend; the middle bar is a small-bodied green candle, that closes below the first red bar; and, the last bar is a large green candle that opens below the middle candle and closes near the center of the first bar\’s body. This pattern is used by traders as an early indication the downtrend is about to reverse.

 EVENING STAR (bearish) – An evening star is a bearish candlestick pattern consisting of three candles that have demonstrated the following characteristics: the first bar is a large green candlestick located within an uptrend; the middle bar is a small-bodied red candle, that closes above the first green bar; and, the last bar is a large red candle that opens below the middle candle and closes near the center of the first bar\’s body. This pattern is used by traders as an early indication the uptrend is about to reverse.

 BULLISH KICKER (bullish) – A two-bar candlestick pattern that is used to predict a change in the direction of the trend for an asset\’s price. This pattern is characterized by a very sharp reversal in price over the span of two candlesticks; traders use it to determine which group of market participants is in control of the direction. The bullish version is a two pattern from red to green.

 BEARISH KICKER (bearish) – A two-bar candlestick pattern that is used to predict a change in the direction of the trend for an asset\’s price. This pattern is characterized by a very sharp reversal in price over the span of two candlesticks; traders use it to determine which group of market participants is in control of the direction. The bearish version is a two pattern from green to red.

HOW DO YOU SET UP YOUR OWN PATTERNS?

The “real power” of this script is that it allows the seasoned daytrader to create their own custom candlestick patterns that this script then hunts for (in near real time from any desktop, laptop, tablet or mobile computer/phone).

To define a custom pattern, simply edit the file called config.php found in the php folder off the root (/php/config.php). In this file you will find the array ”$patternSettings” that contains the “out of the box” patterns this script searches for. See the previous section for the list.

To add your own pattern, simply add to this array. The properties of each array object are pretty self explanatory. The last 15 candlesticks on your chart are objects you can reference in an “if condition” (see “eval” property below) that defines your custom pattern. $value is the object of the most recent candlestick created, $valueMinus1 is the previous candlestick, $valueMinus2 is the one before that and so on until $valueMinus15. The open, high, low, close values are just properties in the object (e.g. $value->open, $valueMinus1->close, $valueMinus15->high…).

For example, see below the definition for the bullish harami pattern:

For example, see below the definition for the bullish harami pattern:

array(
“ID”=>”blHaram”,
“eval” => “return (\$valueMinus2->open > \$valueMinus2->close && \$valueMinus1->open > \$valueMinus1->close && \$valueMinus1->open > \$value->close && \$value->close > \$value->open && \$valueMinus1->close < \$value->open);”,
“title” => “BH”,
“description” => “Bullish Harami”,
“color” => ”#7dd0b6”,
“text” => ’

BULLISH HARAMI (bullish) – A bullish Harami is a trend indicated by a large red candlestick followed by a much smaller green candlestick with a that body is located within the vertical range of the larger red candle body. Such a pattern is an indication that the previous downward trend is coming to an end.


),

NARRATIVE DESCRIPTION: Here is a narrative description of the definition above. First look at the rule in “eval” property. It says look at the two previous candlesticks ($valueMinus1 and $valueMinus2) and make sure they are in a downtrend (e.g. their close values are less than their opens). Then look at the current candle’s ($value) close and make sure it is less than the previous candle’s ($valueMinus1) open and finally make sure current candle’s open is greater than previous one’s close.

The rest of the properties are pretty self explanatory:

ID – unique ID for the pattern
eval – (we just taled about above)
title – letters that appear in the flag
description – friendly description of the pattern
color – color of the flag
text – html of what appears in the “hover” bubble for the patterns flag

HOW TO USE THE SCRIPT

  1. To install/run the script, unzip the contents of the purchased zip file into the root folder of your domain/subdomain and then enter URL in a browser(e.g. http://stocktracker.dataninja.biz or http://yourdomain.com or http://yoursubdomain.yourdomain.com, etc)
  2. Enter the ticker symbols of the stocks you want to track. They can be from the following list of exchanges – (click here for all the exchanges Tradier.comsupports)
  3. Select the candlestick patterns you would like this script to hunt for. This is based on the patterns defined in /php/config.php file. (See instructions on defining patterns in previous section)
  4. Select the interval duration of your candstick (e.g. 1 minute, 5 minute or 15 minute)
  5. Select the type of moving average you want displayed on your chart (e.g. SMA – simple moving average, EMA – exponential moving average, etc) They can be from the following list (click here for all the exchanges alphavantage.co supports). Moving averages are used by daytraders to determine support and resistance levels of stocks. Graphing this value is included in this script (see orange lines)
  6. Select the moving average period to use for orange line (e.g. 10 day average, 15 day average, 30 or 60 or 90 or 120 day averages)

WHAT ARE THE SCRIPT’S KEY FEATURES?


FEATURES – see blue squares above

  1. This script’s main panel is a combination highstock chart (see highsoft.com) that is fed “near realtime” from two FREE stock quote API calls. Realtime and historical stock price information comes from a service called Tradier (see tradier.com and the technical anlaysis (moving averages, etc) comes from a service called Alpha Vantage (see alphavantage.co). The combination chart displays stock quote area line graph on top pane, a candlestick chart in the main pane, volume chart in the third from top pane and then range finder for the entire chart in the bottom pane. (the foundation can be found in the following Highstock demo page – click here)
  2. Real time 1 minute, 5 minute and 15 minute candlesticks, generated as trading day progresses.
  3. Candlesticks that follow defined pattern are hunted for and identified by these circular flags. Gray flag means neutral behavior (e.g. doji’s), green flag means bullish behavior (e.g. bullish engulfing, etc), red flag means bearish behavior (e.g. bearish engulfing)
  4. Mouseover (hover) over a flag and popup (tooltip) description of the pattern found is displayed.
  5. Technical indicator line charts (see orange line – e.g. simple moving average, exponential moving average) are overlayed on top of price and candlestick charts, to help with identifying ssupport and resistance levels.
  6. Real time stock price quote in a area line chart
  7. Real time stock volume in a column chart
  8. Highstock range selector to zoom in and out of chart’s date ranges
  9. Highstock range panning. For desktop/laptop, use shift+leftmouse and drag to pan. For tablet/mobile device, use two finger swipe.
  10. More zooming – toggle to zoom in by highlighting area to zoom into.
  11. OHLC (open, high low, close) quote every 5 seconds
  12. Countdown to when next candlestick will get generated
  13. Repsonsive nav bar to navigate to different stocks’ charts
  14. Top menu icons for liding panels – settings, stock quote detail, candlestick realtime data, pattern flags sorted by counts

FUTURE IMPROVEMENTS – FROM THE NINJA

I would like this to be the beginning of a series of visualization tools for day traders. With all the amazing backend stock investing related web services available today, it would be great to move the needle in the types of tools available for the independent daytrader.

This would include establishing a community (like open source in software) where fellow traders can help each other be successful. Daytrading is small enough that it does not need to be zero sum game. e.g. everyone can win. From technical standpoint, I would like to see any functionality found in these scripts (especially real time feeds) incorporated into my popuplar dashboard scripts.

-Data Ninja

AUTHOR’S NOTE ON SCRIPT: see blog post – Author’s Note: PHP Daytrader’s Candlestick Hunter

REMINDER ON EXTENDED LICENSES: Just a friendly reminder that there are two different license levels at codecanyon.net. The regular license is for single FREE user use. If you have multiple clients or charging clients for functionality from this script, then an extended license is the appropriate level. It’s only fair as I do spend a lot of time tuning these scripts. And more sales/revenues means I can code more features and it has come to my attention that many purchasers are using my script for commercial (for pay) purposes with just the regular license. Thanks for you support. Click for more details – Regular vs. Extended License Comparison

NOTE ON INSTALLATION

  • Purchase script from codecanyon.net
  • Unzip contents on the ROOT folder of your domain or subdomain. DO NOT TRY TO RUN FROM A FOLDER IN YOUR DOMAIN. WILL NOT WORK
  • Sign up for API key from alphavantage.co and enter in the /php/config.php file
  • Sign up for access token from developer.tradier.com and enter in the /php/config.php file
  • Sign up for an appropriate highsoft license for your project (note this script uses a hosted version of the highstock plug in. No installation necessary for highsoft plug in)
  • This script includes 100% of source code. You can customize to integrate into your software/web application. Please see REMINDER ON EXTENDED LICENSES to make sure you a purchasing the correct license level.

SYSTEM REQUIREMENTS

  • Any browser that supports HTML5/Javascript, jQuery (2.1.4). Tested with Chrome Version 49.0.2623.110 (64-bit), Safari Version 5.1.7 (7534.57.2), Internet Explorer 11.0.9600.18230, Firefox 5.0.2
  • A PHP/MySQL supported webserver is required for jsfiddle features (preview, share, save) and render script options #3 and #4 – click here for phpinfo for PHP/MySQL versions and configuration options of the server serving up the demo. IMPORTANT: make sure to compare with phpinfo of your installation. Many PHP/MySQL errors stem from configuration options of customer php server instances.
  • This script uses hosted libraries for Highsoft (code.highcharts.com, etc) and no installation required. It does require you to procure the appropriate Highsoft (Highcharts, Highmaps, Highstock) license based on your use. Click here for details.
  • See ‘Note on installation’ to install this script on your server.

VERSION HISTORY – PHP Daytrader’s Candlestick Hunter

    • VERSION 1.0 (9/4/2017) – Initial launch version

  1. This script’s main panel is a combination highstock chart (see highsoft.com) that is fed “near realtime” from two FREE stock quote API calls. Realtime and historical stock price information comes from a service called Tradier (see tradier.com and the technical anlaysis (moving averages, etc) comes from a service called Alpha Vantage (see alphavantage.co). The combination chart displays stock quote area line graph on top pane, a candlestick chart in the main pane, volume chart in the third from top pane and then range finder for the entire chart in the bottom pane. (the foundation can be found in the following Highstock demo page – click here)
  2. Real time 1 minute, 5 minute and 15 minute candlesticks, generated as trading day progresses.
  3. Candlesticks that follow defined pattern are hunted for and identified by these circular flags. Gray flag means neutral behavior (e.g. doji’s), green flag means bullish behavior (e.g. bullish engulfing, etc), red flag means bearish behavior (e.g. bearish engulfing)
  4. Mouseover (hover) over a flag and popup (tooltip) description of the pattern found is displayed.
  5. Technical indicator line charts (see orange line – e.g. simple moving average, exponential moving average) are overlayed on top of price and candlestick charts, to help with identifying ssupport and resistance levels.
  6. Real time stock price quote in a area line chart
  7. Real time stock volume in a column chart
  8. Highstock range selector to zoom in and out of chart’s date ranges
  9. Highstock range panning. For desktop/laptop, use shift+leftmouse and drag to pan. For tablet/mobile device, use two finger swipe.
  10. More zooming – toggle to zoom in by highlighting area to zoom into.
  11. OHLC (open, high low, close) quote every 5 seconds
  12. Countdown to when next candlestick will get generated
  13. Repsonsive nav bar to navigate to different stocks’ charts
  14. Top menu icons for liding panels – settings, stock quote detail, candlestick realtime data, pattern flags sorted by counts

Regards,
Ninja
my email: dataninja.at.codecanyon@gmail.com
my codecanyon portfolio: click here