I am having trouble on how to input data with frequency in Mathematica. For example, I have 0 with 10,000 frequencies, 1 with 9000 freq, 2 with 3000 freq and 4 with 1000 freq. Can anyone help me to input this data into mathematica and then I need to find the first, second and third moment of those numbers. Thanks a lot!

Something like :

```
data = Join[ConstantArray[1, 9000], ConstantArray[2, 3000], ConstantArray[4, 1000]];
Mean[data]
Variance[data]
Kurtosis[data]
```

```
Table[
fun[
EmpiricalDistribution[
{10000, 9000, 3000, 1000} -> {0, 1, 2, 4}
]
],
{fun, {Mean, Variance, Kurtosis}}
]
```

Similar Questions

Let's say I use the wave module to get raw PCM data from a sound file. How can I compute the amplitude of the contained frequencies of a specific sample? I later want to draw a frequency graph like th

How can I define a function f(x) in Mathematica that gives 1 if x is in [-5, -4] or [1, 3] and 0 otherwise? It's probably something simple but I just can't figure it out!

I'm trying to count how many times a certain number occurs in a column (or row) in excel. I've tried this with the FREQUENCY comando in Excel, but this does not give me the right numbers. So how would

I've been looking around for some data about naming trends in USA. I managed to get top 1000 names for babies born in 2008. The data is formated in this manor: male.name n.male female.name n.female J

I want to know if it is a possiblility to find the frequency string data occurs in the table which contain strings. I find there is a FREQUENCY function, but it is to find the frequency numeric data o

I am new to Mathematica and currently working with time series data. I have the following input data in Mathematica 9.0 data = {{{2011, 3, 13}, 10}, {{2011, 3, 14}, NA}, {{2011, 3, 15}, 20}, {{2011,

I have two frequency tables created using R's table() function: freq1 <- table(unlist(strsplit(topic_list1, split=;))) freq2 <- table(unlist(strsplit(topic_list2, split=;))) topic_list1 and

I am using JQuery-Mobile datebox , and I want to set date input data-options using JQuery edit: my question is : how to set date input data-options using jquery ? input code : <input name=mydate

I have bumped into this problem several times on the type of input data declarations mathematica understands for functions. It Seems Mathematica understands the following types declarations: _Integer,

html <input type=text name=PName /> <input type=text name=PAddress /> <input type=text name=PCity /> mysql table _______________________________________________________

I am looking for some help with a Poisson Solver I am writing in Mathematica. The code is quite long with Arrays plugged in, but the full details can be found at http://pastebin.com/uSrSDcW6 I am calc

In other words, I am trying to play a .wav file and for doing this I need to know the frequency and how much it lasts; the API I am using has a method that need as parameter a vector with two fields (

I have list of integers and want to get frequency of each integer. This was discussed here The problem is that approach I'm using gives me frequency of floating numbers when my data set consist of int

How do I print the number of upper case characters whose frequency is above a threshold (in the tutorial)? The homework question is: Your task is to write a function which takes as input a single non

Compare voice wav in android or voice tag ( voice commands ) API in answer number 2 I don't know how to convert the time-domain data of the original WAV file into frequency-domain data.

i want to get all data to be put in input box where i will select in option box the name of the ingredients that i want to view for example in my data my ingID has a 1,2,3 name has a potato,carrot,bea

I have a data.frame and I'm trying to create a frequency table that shows the frequency of values for each row. So I'm starting with something like this: d <- data.frame(a=c(1,2,3), b=c(3,4,5), c=c

Hi, I want to know how to pass the data into the input type field; I'm using only $_POST method and also I did not use the database first. Please help. form.php <form action=booking.php method=

My goal is to be able to process a single note from a guitar (or other instrument), and convert it into a frequency value. This does not have to be in real time- I figured it would be much easier to r

I'd like to syntax highlight Mathematica code on a MediaWiki site. I've already installed the MediaWiki extension SyntaxHighlight GeSHi and verified that it works for other languages. I tried simply p

I want to develop app to calculate Sound frequency in Android. Android Device will take Sound from microphone (i.e. out side sound) and I have one color background screen in app. on sound frequency ch

The output to my mathematica cell is just a long algebraic equation produced from Solve[%, Subscript[u, i, j + 1]]. {{Subscript[u, i, 1 + j] -> (1/( 2 h^2))(-2 h^2 k Subscript[f, i, j] + 2 h^2 Subs

I use this to create a Bar Chart: BarChart[ Reverse@data, BarOrigin -> Left, ChartLabels -> Placed[{Reverse@labels, Reverse@data}, {Before, After}], ChartElementFunction -> FadingRectangle

For a few weeks now, I have been trying to implement a DFT that takes an arbitrary set of bytes and treats them as a signal. It then transforms them to the frequency domain. Following that it transfor

I have a data frame indexed with a date (Python datetime object). How could I find the frequency as the number of months of data in the data frame? I tried the attribute data_frame.index.freq, but it

Edit: Fixed duplication error in code. I attempted to create a word frequency analysis program that reads in from standard input. I have two questions. Currently I am using '\n' to indicate when my p

This question already has an answer here: How to get frequency of word in a sentence in R? 1 answer if I have a vector x <- c(ajjss,acdjfkj,auyjyjjksjj) and do: y <- x[grep(jj,x)

I have this expression in Mathematica: (a^2 (alpha + beta)^2)/(b^2 + c^2) + (a (alpha + beta))/(b^2 + c^2) + 1 As you can see, the expression has a couple of subexpressions that repeat throughout it.

I have a table with hundred' of record where a field is paired with a similar field based on an id. I want to know what is a good data structure for keeping frequency counts for the number of times a

I want to get a Number Using Input Command In Mathematica and Put it in a Variable.But When I Use This Command And Enter a Number,It Returns Null.Here's the Code: In[1]:= var = Input[Please Enter

I want to remove a certain frequency range from an audio file which is uploaded to the server. I learnt that SoX command has such capabilities. I couldn't find the exact way to accomplish this. Any h

I am trying to plot a vector field from data file. I can put the data into file in any way, but for now data file contains information in this form: x y Fx Fy where Fx and Fy are x and y components of

I have a data set that is as follows: library(data.table) test <- data.table(structure(list(Issue.Date = structure(c(16041, 16056, 16042,15990, 15996, 16001, 15995, 15981, 15986, 15996, 15996, 1600

How can I convert .eps to .pdf inside Mathematica (perhaps using GhostScript?)?

I had created a 3 three different frequency signal and filter out the signal i don't want. But when i using ifft in matlab, it shows a wrong graph.How to transform my frequency domain spectrum back in

wolfram alpha accepts latex, but it does not export to latex, it exports plaintext,rendered images and mathematica sytax. Is there any javascript library that converts the output to latex? Mathematica

Good evening, experts I want to solve recurrence equation using mathematica, x(n) = x(n − 1) + n for n > 0, x(0) = 0 And i need to find x(1), x(2), x,(3) This is my input and it gives me errors n

I am currently working on a graphing program in MATLAB that takes input and maps a point to x-y space using this input. However, the program should also output a continuous tone whose frequency varies

This might be simple but I can't figure it out. I'm trying to print out the frequency of the user input. For example how many times the user enters the number 1? Here is some of my code. import java.u

I want to numerically integrate the following: where and a, b and β are constants which for simplicity, can all be set to 1. Neither Matlab using dblquad, nor Mathematica using NIntegrate can deal w

Given a data set with something like: [2, 3, 4, 5, 6, 7, 8, 9, 10, 15, 20, 25, 30, 35, 40, 45, 50, 55, 65, 75, 85, 86, 87, 88] The values are always increasing (in fact it's time), and I want to find

I defined some variable in the beginning of a Mathematica notebook and used it afterwards to calculate my results. Now I want to do the same calculation several times for different values of the varia

I want to set the id of an input box which am getting in for loop using knockout. How do I set this? <div data-bind=foreach: testData> <span class=cld data-bind=text:flid/> <inpu

I just noticed that the scheduled workflow runner in Aviarc now has a 'Custom' frequency. How do I specify this?

I want to save these form inputs in a file (e.g XML) in order to be able to use it later in the form again: <html> <body> <form action=demo_form.asp> First name: <input type=te

How can I validate the user input by using scanf. Right now I have something like this, but doesn't work. NOTE: I have the atoi just to validate that the scanf validation works. scanf(%[0987654321.-]

I'm a newbie in Mathematica and I'm having a major malfunction with adding columns to a data table. I'm running Mathematica 7 in Vista. I have spent a lot of time RFD before asking here. I have a data

Possible Duplicate: option in dropdown box that changes an input box I am building a scheduler using php-mysql. I have a drop down list for course code and an input box that displays automatically t

I am using the following request to post data to the REST api using PUT method: CURL.EXE -i -H Content-Type: application/json -X put -d '{lat:56.87987,lon:97.87678234}' http://webservice.dev:808

This question already has an answer here: Count occurrence of a character in a string 6 answers Counting each letter's frequency in a string 2 answers I've done this but It's too long, how