Search Results

Search found 1683 results on 68 pages for 'bubble chart'.

Page 10/68 | < Previous Page | 6 7 8 9 10 11 12 13 14 15 16 17  | Next Page >

  • Code golf: Word frequency chart

    - by ChristopheD
    The challenge: Build an ASCII chart of the most commonly used words in a given text. The rules: Only accept a-z and A-Z (alphabetic characters) as part of a word. Ignore casing (She == she for our purpose). Ignore the following words (quite arbitary, I know): the, and, of, to, a, i, it, in, or, is Clarification: considering don't: this would be taken as 2 different 'words' in the ranges a-z and A-Z: (don and t). Optionally (it's too late to be formally changing the specifications now) you may choose to drop all single-letter 'words' (this could potentially make for a shortening of the ignore list too). Parse a given text (read a file specified via command line arguments or piped in; presume us-ascii) and build us a word frequency chart with the following characteristics: Display the chart (also see the example below) for the 22 most common words (ordered by descending frequency). The bar width represents the number of occurences (frequency) of the word (proportionally). Append one space and print the word. Make sure these bars (plus space-word-space) always fit: bar + [space] + word + [space] should be always <= 80 characters (make sure you account for possible differing bar and word lenghts: e.g.: the second most common word could be a lot longer then the first while not differing so much in frequency). Maximize bar width within these constraints and scale the bars appropriately (according to the frequencies they represent). An example: The text for the example can be found here (Alice's Adventures in Wonderland, by Lewis Carroll). This specific text would yield the following chart: _________________________________________________________________________ |_________________________________________________________________________| she |_______________________________________________________________| you |____________________________________________________________| said |____________________________________________________| alice |______________________________________________| was |__________________________________________| that |___________________________________| as |_______________________________| her |____________________________| with |____________________________| at |___________________________| s |___________________________| t |_________________________| on |_________________________| all |______________________| this |______________________| for |______________________| had |_____________________| but |____________________| be |____________________| not |___________________| they |__________________| so For your information: these are the frequencies the above chart is built upon: [('she', 553), ('you', 481), ('said', 462), ('alice', 403), ('was', 358), ('that ', 330), ('as', 274), ('her', 248), ('with', 227), ('at', 227), ('s', 219), ('t' , 218), ('on', 204), ('all', 200), ('this', 181), ('for', 179), ('had', 178), (' but', 175), ('be', 167), ('not', 166), ('they', 155), ('so', 152)] A second example (to check if you implemented the complete spec): Replace every occurence of you in the linked Alice in Wonderland file with superlongstringstring: ________________________________________________________________ |________________________________________________________________| she |_______________________________________________________| superlongstringstring |_____________________________________________________| said |______________________________________________| alice |________________________________________| was |_____________________________________| that |______________________________| as |___________________________| her |_________________________| with |_________________________| at |________________________| s |________________________| t |______________________| on |_____________________| all |___________________| this |___________________| for |___________________| had |__________________| but |_________________| be |_________________| not |________________| they |________________| so The winner: Shortest solution (by character count, per language). Have fun! Edit: Table summarizing the results so far (2012-02-15) (originally added by user Nas Banov): Language Relaxed Strict ========= ======= ====== GolfScript 130 143 Perl 185 Windows PowerShell 148 199 Mathematica 199 Ruby 185 205 Unix Toolchain 194 228 Python 183 243 Clojure 282 Scala 311 Haskell 333 Awk 336 R 298 Javascript 304 354 Groovy 321 Matlab 404 C# 422 Smalltalk 386 PHP 450 F# 452 TSQL 483 507 The numbers represent the length of the shortest solution in a specific language. "Strict" refers to a solution that implements the spec completely (draws |____| bars, closes the first bar on top with a ____ line, accounts for the possibility of long words with high frequency etc). "Relaxed" means some liberties were taken to shorten to solution. Only solutions shorter then 500 characters are included. The list of languages is sorted by the length of the 'strict' solution. 'Unix Toolchain' is used to signify various solutions that use traditional *nix shell plus a mix of tools (like grep, tr, sort, uniq, head, perl, awk).

    Read the article

  • Excel - graphing mean and standard deviation

    - by joe_shmoe
    Hi all, I have measurements for multiple devices, and have their mean and sd values. I would like to produce a chart that would show these values, and I think the best would be if I could have something that looks like a bar chart(-ish) - the device names in x axis, values in y axis, and for each device to have a 'floating' bar that would represent values (mean - sd :: mean + sd), and some marker in the middle to show the actual mean value. is it doable? or would you suggest some other chart? Thanks a lot

    Read the article

  • Daylight Saving Time Visualized

    - by Jason Fitzpatrick
    When you map out the Daylight Saving Time adjusted sunrise and sunset times over the course of the year, an interesting pattern emerges. Chart designer Germanium writes: I tried to come up with the reason for the daylight saving time change by just looking at the data for sunset and sunrise times. The figure represents sunset and sunrise times thought the year. It shows that the daylight saving time change marked by the lines (DLS) is keeping the sunrise time pretty much constant throughout the whole year, while making the sunset time change a lot. The spread of sunrise times as measured by the standard deviation is 42 minutes, which means that the sunrise time changes within that range the whole year, while the standard deviation for the sunset times is 1:30 hours. Whatever the argument for doing this is, it’s pretty clear that reason is to keep the sunrise time constant. You can read more about the controversial history of Daylight Saving Time here. Daylight Saving Time Explained [via Cool Infographics] 6 Ways Windows 8 Is More Secure Than Windows 7 HTG Explains: Why It’s Good That Your Computer’s RAM Is Full 10 Awesome Improvements For Desktop Users in Windows 8

    Read the article

  • .NET WPF Charting Control

    - by Randy Minder
    We're very close to wrapping up a WPF dashboarding application using SSRS (.RDLC files) and the Microsoft Report Viewer. For a number of reasons, this combination has turned out to be less than what we had hoped. One of the biggest problems is that the Microsoft Report Viewer is not a WPF control. We've had other problems as well. Our app consists of at least 5 tabs and each tab has at least 4-5 charts on it. All the charts update on their own timed schedules (like every 15-30 minutes). For the next version I'd like to explore other .NET charting tools for WPF. Performance is absolutely critical. As is resource usage. The tool must support WPF and as many chart types as possible. Can anyone recommend (or not recommend) charting tools they have experience with? We own Telerik and I've dabbled with their charting control. At the 30K foot level, it seems quite nice.

    Read the article

  • bidirectional bubble sort

    - by davit-datuashvili
    Here is the code for shacker sort or bidirectional bubble sort. Something is wrong. Error is java.lang.ArrayIndexOutOfBoundsException Can anybody help me? public class bidirectional{ public static void main(String[]args){ int x[]=new int[]{12,9,4,99,120,1,3,10}; int j; int n=x.length; int st=-1; while (st<n){ st++; n--; for (j=st;j<n;j++){ if (x[j]>x[j+1]){ int t=x[j]; x[j]=x[j+1]; x[j+1]=t; } } for (j=n;--j>=st;){ if (x[j]>x[j+1]){ int t=x[j]; x[j]=x[j+1]; x[j+1]=t; } } } for (int k=0;k<x.length;k++){ System.out.println(x[k]); } } } thanks i have got result thanks guys i have accepted all answers

    Read the article

  • Bubble sort dropped images based on their names

    - by user2259784
    I have written a simple bubble sort function that sort an array of Image objects based on image names. For some reason my function is not swapping the elements of array when needed ( basically new assignment is not working) Here is my code : listOfFiles = event.dataTransfer.files; sortImages(listOfFiles); function sortImages(listOfFiles) { var re = /[0-9]/; var temp; for( var index=0; index < listOfFiles.length ; index++) { for ( var index2=0; index2 < listOfFiles.length-1 ; index2++) { var one = parseFloat(re.exec(listOfFiles[index2].name )); var two = parseFloat(re.exec(listOfFiles[index2+1].name)); console.log(one + " : " + two); if (one > two) { console.log(listOfFiles[index2+1]); console.log(listOfFiles[index2]); //following three lines don't work temp = listOfFiles[index2+1]; listOfFiles[index2+1] = listOfFiles[index2]; listOfFiles[index2] = temp; console.log(listOfFiles[index2+1]); console.log(listOfFiles[index2]); } } } }

    Read the article

  • bubble sort logic error

    - by Arianule
    I was trying a basic sorting exercise and I was hoping I could receive some help with what is probably a basic logic error. int[] numbers = new int[] { 2, 5, 11, 38, 24, 6, 9, 0, 83, 7 }; for (int loop = 0; loop < numbers.Length; loop++) { Console.WriteLine(numbers[loop]); } Console.WriteLine("Performing a bubble sort"); bool flag = false; do { for (int loop = 0; loop < numbers.Length - 1; loop++) { if (numbers[loop] > numbers[loop + 1]) { int temporary = numbers[loop]; numbers[loop] = numbers[loop + 1]; numbers[loop + 1] = temporary; flag = true; } } } while (flag == false); for (int loop = 0; loop < numbers.Length; loop++) { Console.WriteLine(numbers[loop]); } kind regards arianule

    Read the article

  • Radar chart color inner circles

    - by JJ
    Hello, Is it possible to color the inner circles of a radar chart. I want to color each section differently The image below should clarify: Wanted radar chart Thanks in advance! Kind Regards, JJ

    Read the article

  • adding opacity's of the PhoneAccentBrush to a Silverlight toolbox pie chart

    - by Doug
    Hi there, i am working on a windows phone application and i am using the pie chart - i am relatively new to the silverlight control toolbox. i want to make my pie chart use different opacity's of the PhoneAccentBrush as its colour pallete. (ie if the accent colour is green then i use the green and then a 0.8,0.6,0.4,0.2 opacity of the colour as my pie charts pallete) i have tried a few things, but none of them worked - has anyone accomplished this and if so how? thanks in advance Doug

    Read the article

  • How to implement Open Flash Chart 2 on Symfony

    - by victmo
    I'm trying to use Open Flash Chart 2 on my symfony project by including the ofc2 library on one of my controller's action. Unfortunately it doesn't work. There is a plugin for this, but it doesn't play with the latest version of OFC. Anyone have had any success showing Open Flash Chart 2 on their site? Thanks in advance, Vic

    Read the article

  • Javascript Chart to Excel

    - by George
    Hi I'm using highcharts to create some charts (pie, bar, etc...) using just Javascript. These charts do not use Flash or anything like that. Is it possible for me to convert the resulting HTML page with the Javascript chart to an excel document that properly shows the image? I've tried the standard change mime types for excel and so far I've only been able to export an HTML table on the page, but no chart.

    Read the article

  • SQL Server Reporting Services: creating a Pareto chart

    - by william
    I am trying to create a Pareto Chart in SQL Server Reporting Service 2005. I created a chart, but having difficulties in trying to get my cumulative(line) to display. I listed my values below. =SUM(Fields!Total_SR.Value)/MAX(Fields!Total_SR.Value, "SeriesGroup")*0.75 cumulative value: =RunningValue(Fields!Total_SR, Sum, "SeriesGroup") / Sum(Fields!Total_SR, "SeriesGroup") I am able to get the Bar to display. This is the instructions I used: http://msdn.microsoft.com/en-us/library/aa964128(SQL.90).aspx

    Read the article

  • Adding Chart to WordprocessingML

    - by kern
    I would like to generate an Open XML document containing a Chart using the Open Xml SDK 2. I found an SpreadsheetML example, but I can't work out how to add the chart in a .docx... Is there a good source for documentation/examples for the Open Xml SDK 2?

    Read the article

  • Build hierarchical chart using flex and action script

    - by jk
    i want to develop an application using flex 4 sdk with eclipse and action script. i need to draw the hierarchy chart dynamically and save it. should be able to label all the nodes at runtime, should able to view all charts created previously saved chart. i need source code for this sample application http://live.yworks.com/graphity/ thanks in advance

    Read the article

  • Gantt Chart Via Using Sharepoint

    - by Gayan J
    Hay.. i Need A Help For Creating A Share Point simple web Site And Add Gantt Chart. The Main thing hear Was to Update That Gantt Chat Via Using data Base.Main Thing Hear Was,Need To Draw A gantt chart by using Data Base. Do you Have Any Idea About That????

    Read the article

  • C# : MS Chart : SeriesCollection -> InvalidCastException?

    - by HeinrichStack
    What is the correct way to get the Series of a char in PPT 2010. I tried PowerPoint.SeriesCollection mySeriesCollection = (PowerPoint.SeriesCollection) myChart.SeriesCollection(1); throws the following exception Exception Type: System.InvalidCastException Further, What is the correct call in C# to get the series of a chart ? If I try this way: PowerPoint.Series mySeries = (PowerPoint.Series)myChart.SeriesCollection.Item(1); I get the following compile error : error CS0119: 'Microsoft.Office.Interop.PowerPoint.Chart.SeriesCollection(object)' is a 'method', which is not valid in the given context

    Read the article

  • Workfow foundation 4.0 Flow chart

    - by Sandy
    We already have our own workflow engine implemented about 5 years ago, currently we are thinking of leveraging the new flow chart control in .net 4.0 for the visual presentations of our existing states. So can we simply using this flow chart control without using other workflow foundations features?

    Read the article

< Previous Page | 6 7 8 9 10 11 12 13 14 15 16 17  | Next Page >