pystitch / stitch

Write reproducible reports in Markdown
https://pystitch.github.io
MIT License
441 stars 20 forks source link

LaTeX issues #10

Closed TomAugspurger closed 8 years ago

TomAugspurger commented 8 years ago
jankatins commented 8 years ago

for the first item: or use pandoc to convert from html tables to latex tables: https://github.com/janschulz/knitpy/blob/master/knitpy/documents.py#L339-L366

TomAugspurger commented 8 years ago

Thanks, I have a semi-large refactoring going on in https://github.com/TomAugspurger/stitch/pull/11 that addresses most of these.

By the way, I think https://github.com/jgm/pandoc/commit/244cd5644b44f43722530379138bd7bb9cbace9b will help with image sizing stuff. Just tested it out, by hardcoding a width and height inside the Image constructor and it worked. Just need to plumb the width / height from the chunk options down to the output wrapper.

jankatins commented 8 years ago

Re images: The problem I usually have is getting goodlooking images into the document (no matter if rmarkdown or word) -> if they get resized they look blurry because the antialising which happens in the plot backend is way better than the resizer algo in the browser/word and resizing images also messes up text size between images if they get resized differently :-/ (e.g see the discussion here, although it doesn't mention the image quality: http://r4ds.had.co.nz/graphics-for-communication.html#saving-your-plots -> 28.7.1 Figure sizing).

So IMO this needs something similar to how knitpy handles the prefered image format (e.g. https://github.com/janschulz/knitpy/blob/master/knitpy/documents.py#L48-L61 which then gets set per engine https://github.com/janschulz/knitpy/blob/master/knitpy/engines.py#L42-L53) -> e.g. each language needs a wrapper which sets image types (based on chunk option but per default based on the final output format) and the current image size (based on the sizes in the chunk options).

TomAugspurger commented 8 years ago

Closed by c8c48fc4c94f8508cfe341962e80a0fdb3df76ba

Will open a second issue for the image DPI / sizing stuff.