ExtJS Pie Chart Example

Problem You want to display a pie chart. Solution Use the Ext.chart.Chart, and set several properties under the “series” property to render a pie chart. Ext.onReady(function() { Ext.define(’PopulationPoint’, { extend: ‘Ext.data.Model’, fields: [’state’, ‘population’] });   var store = Ext.create(’Ext.data.Store’, { model: ‘PopulationPoint’, data: [{ state:"Alabama", population: 4802740}, { state:"Alaska", population: 722718}, { state:"Arizona", population: […]

ExtJS Line Chart Example

Problem You want to display a line chart. Solution Use the Ext.chart.Chart.   Ext.onReady(function() { Ext.define(’PopulationPoint’, { extend: ‘Ext.data.Model’, fields: [’state’, ‘population’] });   var store = Ext.create(’Ext.data.Store’, { model: ‘PopulationPoint’, data: [{ state:"Alabama", population: 4802740}, { state:"Alaska", population: 722718}, { state:"Arizona", population: 6482505}, { state:"Arkansas", population: 2937979}, { state:"California", population: 37691912}, { state:"Colorado", population: […]

, ,

Finding the beat in R

In a previous article, I described a method for detecting chords in an audio file (also available for Scala). Continuing on this theme, the following will find the onset of a drumbeat in a file, using R. I’m using a single drumstick click, which you can hear on freesound.org. This method detects sudden volume increases- […]

, , ,

Book Review: R Cookbook

The R Cookbook is written by Paul Teetor, a developer with degrees in statistics and computer science, specializing in finance. The programming language R is a specialized language designed for deep statistical research, although it has some support for other mathematical fields, such as matrix algebra and signal processing. True to the O’Reilly cookbook format, […]

ExtJS HtmlEditor Example

Problem You want to display a control that allows editing HTML. Solution Use the HtmlEditor xtype. <script> Ext.onReady(function() { Ext.tip.QuickTipManager.init(); // enable tooltips var panel = new Ext.panel.Panel({ title: ‘HTML Editor’, renderTo: "html", width: 473, height: 220, default: ”, frame: true, layout: ‘fit’, items: { xtype: ‘htmleditor’, enableColors: true, enableAlignments: true, enableLists: true, enableSourceEdit: true […]

ExtJS xtemplate Example

Problem You want to use an html template within client-side ExtJS code. Tested in ExtJS Version 4.1.1 Screenshot Solution Use ExtJS’s xtemplates. Ext.onReady(function() { var trackStore = new Ext.data.Store({ storeId: ‘soundCloudStore’, proxy: { type: ‘ajax’, url: ‘blues.json’, reader: { type: ‘json’, idProperty: ‘id’ } }, fields:[’duration’, ‘genre’, ‘created_at’, ‘kind’, ‘title’, ‘id’] }); trackStore.load( function(records, operations, […]

What I learned from a failed iPad app

About a year ago, I thought I’d build a small news app that played a series of videos from youtube- a news channel for people without cable. Fortunately, in the mean time, someone built this. There are several interesting possibilities from this – to see news that is not normally available in your country, and […]

ExtJS Tooltip Example

Problem You want to display a grid with a tooltip. Tested in ExtJS Version 4.1.1 Screenshot Solution Set the “tip” property on the GridPanel’s view (panel.getView().tip). view = this.getView(); view.tip = Ext.create(’Ext.tip.ToolTip’, { target: view.el, delegate: view.itemSelector, trackMouse: true, renderTo: Ext.getBody(), listeners: { beforeshow: function updateTipBody(tip) { tip.update("Tooltip!"); } } Discussion The example ExtJS provides […]

,

New tool explores Flippa seller history and facilitates due diligence

Clinton, owner of Experienced-People.net, released a new data analysis tool to explore Flippa auction history, available at http://stats.experienced-people.net/seller.php. Flippa is one of the largest marketplaces for websites for sale- this tool allows detailed research on sellers to facilitate due diligence and market research. One of the most fascinating part of browsing Flippa listings, for me, […]

ExtJS ListView Example

Problem You want to display a grid which lists a series of objects. Solution Use a GridPanel (aka ListView): Ext.require([ ‘Ext.grid.*’, ‘Ext.data.*’, ‘Ext.util.*’, ‘Ext.state.*’ ]);   Ext.onReady(function() { var trackStore = new Ext.data.Store({ storeId: ‘soundCloudStore’,   proxy: { type: ‘ajax’, url: ‘blues.json’, reader: { type: ‘json’, idProperty: ‘id’ } }, fields:[’duration’, ‘genre’, ‘created_at’, ‘kind’, ‘title’, […]