# Tag Info

15

Short answer: I hope Export["foo.pdf", plot,Background->None] fixes it. Let's get there step by step. First, Acrobat X Pro on my Mac reports that both your PDF files are fine. They print fine, and pass all tests with flying colors. I uncompressed the PDF (thanks pdftk) and a diff on them reveals that one weird object that only appears in your ...

13

You can set this in a style sheet so that it is done once and you don't have to do it again: Cell[StyleData[All, "Printout"], ShowCellLabel -> False] or can you programmatically add this private style to your notebook: SetOptions[EvaluationNotebook[], StyleDefinitions -> Notebook[{Cell[StyleData[StyleDefinitions -> "Default.nb"]], ...

10

You could uncheck ShowCellLabel under Cell Options > Cell Labels in the Option Inspector. If you only want to turn off input and output cells in the printing environment, you could edit the style sheet of the document. In order to do that you choose Edit Stylesheet... in the format menu. Click on the link to the base definition of the style sheet ...

8

Here is a starting point, which people with palette creation experience could expand on to create a "one click" solution. First, my setup: File number 1: "confidential.nb" with two sections and two text cells. I selected the entire first section and hit CTRL+J to bring up the cell tags: I added the tag "Confidential" to all of the cells. This is what ...

8

You can specify ImageSize in inches. From docs > ImageSize> MoreInformation: Specifications for both width and height can be any of the following: ... 72di di inches (before magnification) ... Examples: Row[{Plot[{Sin[x], Cos[x]}, {x, -2 Pi, 2 Pi}, Frame -> True, AspectRatio -> 1/GoldenRatio, ImageSize -> 72 2], ...

8

Quite redundant after the other answers and links, but I use something like this for vector-based technical drawings and CNC data (using mm as unit). This is not foolproof as it might e.g. screw up with conflicting options and such, so make sure to check the output. Important: SetPlotRange for your graphics explicitely: gfx = Graphics[Line[{{10, 10}, ...

7

Sounds like you are looking for $Messages and$Output, and maybe also $PrePrint or$Post. $Messages and$Output are a list of streams to which corresponding output is written (note that $Output is only getting output from Prints, not from return values of shift-return-evaluations). To cover return values of shift-return-evaluations you might want to ... 6 Your question isn't very specific, so here is a generic example from another question From the documentation for ImageSize: The following settings can be given: 72di di inches (before magnification) Suppose we want to give sizes in centimeters. We establish a scale: cm = 72/2.54; And we give the ImageSize in this scale, also making sure to ... 5 First, I cannot reproduce your issue on Mathematica 8.0.1.0 on 64-bit Linux (CentOS 5.8). But I compare what you obtain and what I see, and I think I have an idea. The notebook does not specifically require fonts, and as such, the font for e.g. your title cell is system-dependent. On my Mac, it uses a bold Helvetica in size 36, while on my Linux box it ... 4 I can only give a partial answer. Your problem arises because FilePrint doesn't use$Output (stdout). It uses the stderr stream, so you can't capture what it writes by using Block and assigning to $Output. Unfortunately, I don't think any system variable is bound to stderr. Perhaps I'm wrong. In that case, I hope a more knowable person will be able to ... 4 Try setting the printing environment on 'Working' using the File > Printing Settings > Printing Environment menu. The default for printing, the Printout stylesheet uses a condensed version of the screen stylesheet. Proof: If you open the stylesheet editor (Format > Edit Stylesheet...) while using the standard notebook style you get this: Click ... 4 I have found one solution, using a temporary file:- streams = AppendTo[$Output, OpenWrite[]]; Module[{}, Print[Plot[Sin[x], {x, 0, 2 Pi}]]; a = 123]; Close@Last@streams; $Output = Most@streams; printoutput = ReadList@First@Last@streams 4 (I posted a similar answer on MathGroup recently.) Here's an alternative to the other very good answers you already received. If you need high accuracy, I recommend exporting to DXF. DXF is a format used by CAD applications requiring precision. Then you can use one of the many DXF-viewers or CAD programs to print to precision. (There seem to be a ... 3 You can temporarily redefine Print, like so: fun[] := Module[{}, Print[Plot[Sin[x], {x, 0, 2 Pi}]]; a = 123] list = {}; Block[{Print = AppendTo[list, {##}] &}, fun[]] Now list contains everything that was printed. (Of course in a practical application you'd probably want to do something smarter than an inefficient periodic AppendTo) If you still ... 3 I've rewritten my answer after you edited yours. Dynamic[ mQ[n_] := 75.63510582933174 - 35.87130621205199 n + 86.18343750838301 n^2 - 55.324190072519976 n^3; mV[t_] := -29.619999999999976 + 5.499999999999998 t + 18.333333333333325 t^2; a = xVariable + 2 - yVariable; {Slider[Dynamic[n, Automatic]], Dynamic[{n, xVariable = mQ[n]}, ... 3 This problem of not printing Exported PDFs originated when upgrading from version 7 to version 8. In version 7 it worked fine. In February 2011, I complained to Wolfram Research, as a Premier Service Member, but they could not fix this at the time. By trial and error I have stumbled upon a workaround. Export the graphics as a Postscript file: ... 3 It looks like something screwy on your system rather than anything specific to your notebook or stylesheet (I downloaded and everything was fine on my Mac). You could try explicitly setting the FontTracking at various levels, Global, Notebook, Cell etc. and see if that helps. SetOptions[EvaluationNotebook[], FontTracking -> "Condensed"] ... 3 Please try setting menu File > Print Settings > Printing Environment to Working and report if the behavior changes at all. Please also try each of these settings and report any effect: SetOptions[$FrontEndSession, PrivateFontOptions -> {"FontType" -> "Outline"}] SetOptions[\$FrontEndSession, PrivateFontOptions -> ...

3

Short answer For me a Print from within a Dynamic goes to the Messages notebook. Have you checked that with a very simple case? If I evaluate this: Column[{Slider[Dynamic[x]],Dynamic[Print[x];x]}] and play with the slider, the Messages notebook will be opened and the x-values are printed to it. If that is not also happening for you, you should provide ...

2

Here is another way you can select every 21st element of your list. sel= Table[mylist[[i]],{i,1,Length@mylist,21}]; Because Mathmatica is interactive, you can then examine one, many or all the selected elements that are held in sel by using expressions like: sel[[1]] (* first element *) sel[[7;;11]] (* elements 7 through 11 *) sel[[{2,6,14}]] ...

2

You can select every 21st element using mylist[[21;; ;; 21]] You can print them using Do[Print[mylist[[i]]], {i, 21, 441, 21}] Regarding memory, having these displayed in the Front End will take more memory than just having the data in kernel memory, so Print /@ mylist[[21;; ;; 21]] may be better. Why do you want to print them? If you're aim is to ...

2

I tried belisarius' answer using WriteString, but it just prints plain text, and you can't print, for example x2. Instead you have to print x^2 which is not cool for reading. I found a way using Google and Mathematica's help. The main thing I was missing was that under each command found in the help of Mathematica you have "More Information" image which if ...

2

I haven't figured out how to add a "Content Removed" label or to hide entire groups of cells, but you can use Style Sheets and the Printout environment to at least automatically Close cells with the style "Confidential" while printing. With this method I think you would need to have a different Confidential style for each cell type (code, text, etc.) that ...

1

You can do this a couple of different ways. This is easiest: NumberForm[MatrixForm @ matrix, {5, 4}] This works because NumberForm affects sub-expressions including ones wrapped in MatrixForm. You can do it the other way but it's more complicated: Map[NumberForm[#, {5, 4}] &, matrix, {2}] // MatrixForm You mention that you eventually want ...

1

It is not clear to me from your question how you want to use this operation. If you create a Button with this code you should be able to click the button to print a selected block of code. Button["Print Selection", FrontEndTokenExecute @ "PrintSelectionDialog" ] If you want to perform this operation programmatically you need to control the selection ...

1

If the problem is about debugging, perhaps this will help: Slider[Dynamic[t], {0, 20}] nb = CreateDocument[]; Dynamic[NotebookWrite[nb, Cell[ToString@t]]] It will give you the output in a separate Notebook. If you would like to write to the same notebook use nb=EvaluationNotebook[]; instead (but I don't recommend it:). EDIT: Adapting this answer also ...

1

Mathematica 9 came out last week, and the problem is less bad (but not gone) in the default stylesheet. As a solution to the initial problem it's not very satisfying, but in practical terms I got a stochastic differential equation solver as a bonus feature to being able to generate half-decent prints. I'll update this answer in case I find out more. (Thanks ...

Only top voted, non community-wiki answers of a minimum length are eligible