# All Questions

1k views

### Rotating 3DPlot into animated gif

I'm trying to make an animated gif of a 3D plot by rotating the plot in its middle, around a vertical axis. I used the tricks gave by F'x and Heike in this thread autorotating 3D plot but I ...
193 views

### Graph does not accept Property Options

My question is concerned with the Graph functionality, which was newly implemented in Mathematica 8. I already used GraphPlot ...
166 views

### Create string from character code

Is it possible to convert a charcode/keycode to a string? I want to do this to create variables in a generated equation.
967 views

### ListContourPlot-ColorFunction

How can I use ONLY the central 90% of the spectrum, not the whole range? For example, I do not like to see the lowest values in purple, but in deep blue color. ...
278 views

### Create self-contained plots when Ticks or FrameTicks require external functions

Let's say I define tick marks for a plot in a separate function outside of the plot: ...
158 views

### Stopping Agglomerative clustering under a condition in Mathematica

How do I instruct Agglomerative clustering to stop/NOT merging two particular clusters if the distance between the two clusters is larger than a threshold value? I know that we can implement a custom ...
2k views

### What is the difference between a few simplification techniques?

I am trying to understand the difference between Refine, Simplify and FullSimplify, and when ...
2k views

### How to get graph layout that reflects edge weights?

My heart soared to discover that Mathematica 8 offers support for specifying a weighted adjacency matrix in WeightedAdjacencyGraph. But it seems that, regardless of the weights between edges, the ...
2k views

### Data fitting with Image processing feature detection

I have some 2D data that once plotted looks like the following ...
595 views

### Problem with Union and Intersection

Consider the following: list={{a,b,c},{c,d,e},{d,e,f},...{x_,y_,z_}}; I would like to apply Union on the elements of the list ...
161 views

### Joining only particular dates with DateListPlot

I have the following datasets: ...
491 views

### Reproducing nested loops using Map?

I keep producing bits of code like the following: ...
584 views

### Coloring edges in GraphPlot

I'm a little stuck with graph drawing part of my research — I can't use the Graph function for plotting my graphs, because my graph is a multi-graph. ...
2k views

### Append in For loop does not work

I need to break my for loop in case of an thrown message and append s to the result list. Breaking the loop works, but my result is empty. I can not use Table[] ...
698 views

### How to replace all occurrences of an element in a list?

Consider the following: list={1,2,2,2,3}; I would like to replace all 2 with the string "Test". ...
2k views

### How to create a list of pairs from 1d list(s)?

Say I've got two 1-dimensional lists A = {1,2,3} B = {a,b,c} How do I create a list of all pairs from list A such that the ...
1k views

### How to convert binary float to decimal float

I need to convert binary float to decimal float in Mathematica, ideally between any two bases. FromDigits["1.111111", 2] does not work.
4k views

### Legend of a plot: how to increase the size of the line/marker?

I'm using the following kind of code to do the legends of my plots: ...
640 views

### DeleteCases on list of Strings

Consider the following: data={"AB","CD","AF"}; Now I would like to delete all String from data which starts with "A". ...
241 views

### How to make an unremovable modal window?

Is there any way to securely stick a notebook window (e.g. a dialog) on screen that it cannot be closed/removed/hidden by any of the standard OS shortcuts, like AltF4 or AltTab under Windows? The ...
318 views

### Symmetric difference of a sample of lists

Consider the following: list1={a,b,c,d}; list2={c,d,e,f}; list3={g,d,c,h}; Now I would like to get the symmetric difference. Hence, the result must be ...
625 views

While answering this question, I tried TextRecognize to read single digits. But it doesn't recognize a single digit, even though the digits are clearly readable. ...
208 views

### Create a CDF file with a plot that cannot be edited by double-clicking

I have created a CDF file that contains a Manipulate object with a plot. I intend to embed the file in a web site, so that users can use interactive sliders to ...
564 views

### Efficiently deleting rows in many large text files

I have 500 text files each of about 200000 rows. I need to delete one row in each of them as fast as possible (later such operations will repeat). What is the best way to do this with Mathematica? ...
6k views

### Is there an open source implementation of Mathematica-the-language?

I've seen questions before such as "What is the best open-source equivalent for Mathematica?", but that specific question (and that line of inquiry in general) cares more about the computer algebra ...
1k views

### Is it possible to use Mathematica to record sound and/or vision?

I think the title says it all. I know about ImageCapture which seems to capture stills. Can ImageCapture be made to capture a ...
11k views

### Labeling individual curves in Mathematica

I need to create a plot for export and inclusion in a report. Is there a better way to label curves than PlotLegends? From what I've read and my personal ...
352 views

### Custom distance metric for agglomerative clustering in Mathematica

Is it possible to have a custom distance metric defined to determine the distance between two clusters in Agglomerative clustering in Mathematica? I have a 3 dimension data with string values along ...
498 views

### Computing the distance between two curves obtained from image data?

I've got some image data that I've binarized. The image contains two curves, from which I'd like to compute the distance between (eventually computing an average radius for each point in the ...
199 views

### MatchQ and patterns for similar lists

I can't seem to find the right set of patterns to independently match two different lists. Simplified versions of the lists are as follows: ...
412 views

### Shading in squares crossed by a diagonal

You have a rectangle and it is diagonal. How many squares will be crossed by the diagonal (I guess assuming the side length of the rectangle are nice whole numbers) I've seen an implementation in ...
2k views

### Why doesn't Mathematica expand Cos[x]^3 Sin[x]^2?

I found some examples of Mathematica's commands usage in an old manual but the program gives me different result than expected ...
317 views

### How do I define the “Coupon” within the function FinancialBond with a time-varying coupon

Is it possible using FinancialBond function to calculate the yield of a bond paying a gradual coupon ? An example : A bond with maturity of 7 years pays ...
251 views

### Interpreting text entry and splitting it in a Manipulate text field?

I have the following program that plots the number of trigram appearances across a corpus of textual information between 1964 and 1989 (apologies for the messy code): ...
352 views

### Is there a way to print out SQL queries made using DatabaseLink?

I have a Mathematica batch script which makes some MySQL queries using DatabaseLink to store parameters of the run in a database. Recently, I had a run where these queries failed, and there was no ...
768 views

### Using the Krylov method for Solve: Speeding up a SparseArray calculation

I'm trying to implement this Total Variation Regularized Numerical Differentiation (TVDiff) code in MMA (which I found through this SO answer): essentially I want to differentiate noisy data. The full ...
125 views

### Question about scoping data in a multi-level Manipulate construction

Background: In a module containing an outer / inner manipulate I select the key of data with a dropdownlist in the outer manipulate. Data is read and displayed in the inner manipulate for edit ...
531 views

### How can I influence the spaces between labels on a BarChart

I want to chart data using a BarChart, the labels on the x-axis are numbers. Unfortunately they are so close to each other it really looks strange and more like one ...
123 views

### tol and None in output of CompilePrint

A bit of background: I'm trying to fit a very complicated symbolic function. By compiling the function I got about 100x speedup, but I would need another 10. Therefore I'm trying to understand if the ...
2k views

### How can I connect to a database using the 32 Bit ODBC on a Windows 7 (64 Bit) machine?

I am having difficulties using a DSN that was defined in the 32 Bit version of the ODBC-manager? (there are two separate managers for 32/64 Bit on a 64 Bit machine) Using the DatabaseLink package ...
351 views

### Strange domain dependency with Maximize

I'm using Mathematica 8 and strangely enough this code: Maximize[{x*(1-0.01 x),x>0},x,Integers] produces the result ...
168 views

### BoxWhiskerChart too slow on big datasets, how to speed it up?

I have very big dataset, with over 14 000 000 records. And maybe more! Each record consists of Data ( Real ) and Time ( integer ). I group records by time interval, resulting in 300 groups. In each ...
338 views

### Finding a vector field from a set of points

I have a data set of the type $\{x,y,z\}$ where $(x,y)$ is a point and $z$ is the "value" or magnitude at that point. This gives me a triangular sort of shape since $(x,y,z)$ is not defined along the ...
298 views

### How can an InverseQuantile or an interval valued Quantile function be implemented in Mathematica?

Quantile[] is the workhorse method in robust data analysis and statistics (see, eg Koenker's Quantile Regression). However, it should be complemented by an ...
625 views

### Number of iterations in NSolve

In Excel's solver, one can define how many iterations are to be done, to one's liking. I am wondering if this is possible to do with NSolve in Mathematica? Code ...
212 views

### Threading behavior of SameQ vs Equals

I ran into a bug in my code today based on an errant assumption. Namely, I thought that: ...
424 views

How can I calculate only those permutations of Range[n], that satisfy certain rules? I don't want to filter the result after calculating all the permutations but ...
125 views

### Possible to draw an Item in a Grid with only 3 sides of a Frame?

I'm trying to draw a Grid of characters where some of the characters have Frame lines on 3 sides. For example: ...
It is well known from theory that the Coulomb potential can be obtained as a Fourier transform in the following way:  \int \frac{\mathrm{d}^3p}{\left( 2 \pi \right)^3} \frac{e^{\mathrm{i} ...