Creating tables in Bogleheads.org forums

Discussions about the forum and contents
Post Reply
Columbus Investor
Posts: 3
Joined: Mon Oct 28, 2013 7:08 am

Creating tables in Bogleheads.org forums

Post by Columbus Investor » Wed Oct 30, 2013 6:09 am

Can anyone point me to a thread with info about organizing a simple table (or aligned columns) in a forum post?

I've tried Word-to-wiki converters and hand-coding BBCode tags, and I am failing miserably!

In my most recent attempt I included the following tag structure but when I preview it, I see all the markup and no formatting!

[table]
[tr]
[th]heading[/th]
[th]heading[/th]
[/tr]

[tr]
[td]data[/td]
[td]data[/td]
[/tr]
[/table]

placeholder
Posts: 3954
Joined: Tue Aug 06, 2013 12:43 pm

Re: Creating tables in Bogleheads.org forums

Post by placeholder » Wed Oct 30, 2013 12:09 pm

Seems like most people use [CODE] tags.

sscritic
Posts: 21858
Joined: Thu Sep 06, 2007 8:36 am

Re: Creating tables in Bogleheads.org forums

Post by sscritic » Wed Oct 30, 2013 12:10 pm

placeholder wrote:Seems like most people use [CODE] tags.

and the space bar.
and preview.

sscritic
Posts: 21858
Joined: Thu Sep 06, 2007 8:36 am

Re: Creating tables in Bogleheads.org forums

Post by sscritic » Wed Oct 30, 2013 12:12 pm

like this, for aligning the decimal point (period, decimal point, it's all the same).

Code: Select all

and the space bar. 
      and preview.

User avatar
Ketawa
Posts: 1874
Joined: Mon Aug 22, 2011 1:11 am
Location: DC

Re: Creating tables in Bogleheads.org forums

Post by Ketawa » Wed Oct 30, 2013 12:14 pm

In addition to the above recommendations, if you're using Excel, save your worksheet as type "Formatted Text (Space delimited)". Open the resulting file in a text editor like Notepad.

Mudpuppy
Posts: 5434
Joined: Sat Aug 27, 2011 2:26 am
Location: Sunny California

Re: Creating tables in Bogleheads.org forums

Post by Mudpuppy » Wed Oct 30, 2013 12:20 pm

Ketawa wrote:In addition to the above recommendations, if you're using Excel, save your worksheet as type "Formatted Text (Space delimited)". Open the resulting file in a text editor like Notepad.

And if the data is not in Excel, but rather is just something you're generating on the fly, you can start in Notepad (or any other fixed font editor) to get the spacing correct, then copy/paste into a code tag here.

User avatar
Epsilon Delta
Posts: 6492
Joined: Thu Apr 28, 2011 7:00 pm

Re: Creating tables in Bogleheads.org forums

Post by Epsilon Delta » Wed Oct 30, 2013 12:25 pm

As far as I can see tables are not well supported. Additional support would be appreciated. If you intend to use a code block, set your text editor to use a fixed width font. And don't use tabs, how the bogleheads' software interprets tabs is a complete mystery, it might even be random. Tabs surrounded by spaces are even more mysterious.

Alex Frakt
Founder
Posts: 10730
Joined: Fri Feb 23, 2007 1:06 pm
Location: Chicago
Contact:

Re: Creating tables in Bogleheads.org forums

Post by Alex Frakt » Thu Nov 07, 2013 12:04 am

Columbus Investor wrote:In my most recent attempt I included the following tag structure but when I preview it, I see all the markup and no formatting!

[table]
[tr]...

Tables in posts are not directly supported by phpBB, our forum software. Under the original version we used (phpBB 2), I was able to allow specified html tags so I put in all the table tags. PhpBB 3 removed this functionality in favor of custom BBCodes. Unfortunately, (no) thanks to all the new css overhead, it's essentially impossible to set up custom BBCodes for table elements that will display consistently for everyone. Rather than confuse the heck out of some unknown percentage of readers every time a table is used, we've elected not to try.

Using the Code option and spaces is the best way to go. I use an external text editor that has a fixed width font (Word and Courier New works fine) to create these when I need them.

User avatar
#Cruncher
Posts: 2420
Joined: Fri May 14, 2010 2:33 am
Location: New York City
Contact:

Re: Creating tables in Bogleheads.org forums

Post by #Cruncher » Thu Nov 07, 2013 12:43 am

Epsilon Delta wrote:If you intend to use a code block, ... don't use tabs ...
Indeed! Columns separated by tabs may look fine in a text editor, but look erratic in a post. The code directive also has a problem displaying a single leading space.

Code: Select all

0123456789   <-- OK;  has no leading spaces
 0123456789   <-- Bad; has one leading space but it doesn't display
  0123456789 <-- OK;  has two leading spaces
07/15/2017: Edited to add following comment:
The second line in the code block above (the one with a single leading space) now displays properly. Looks like a board software update fixed this bug.
Last edited by #Cruncher on Sat Jul 15, 2017 7:30 am, edited 1 time in total.

fundseeker
Posts: 632
Joined: Mon Dec 24, 2007 9:02 am

Re: Creating tables in Bogleheads.org forums

Post by fundseeker » Sat Jul 15, 2017 6:44 am

Does anyone know if there has been any improvement in getting information from an Excel spreadsheet into a post, without having to re-type it all? And that does not work anyway because you cannot tab over to create columns, and even using the space bar, once you go to preview, all of your work is gone. Any suggestions to copy and paste and still have columns? Thanks.

User avatar
#Cruncher
Posts: 2420
Joined: Fri May 14, 2010 2:33 am
Location: New York City
Contact:

Re: Creating tables in Bogleheads.org forums

Post by #Cruncher » Sun Jul 16, 2017 10:06 am

fundseeker in previous post wrote:Does anyone know if there has been any improvement in getting information from an Excel spreadsheet into a post, without having to re-type it all?
I don't know of anything new. But when I have an Excel table with many rows, I often format it right on the Excel sheet. Here is an example using the Excel LEFT, REPT, RIGHT, ROW, and TEXT functions.

Code: Select all

Row        Column A               Column B

Code: Select all

  2  07-01-2017  Saturday                1
  3  07-02-2017  Sunday                  2
  4  07-03-2017  Monday                  4
  5  07-04-2017  Tuesday                 8
  6  07-05-2017  Wednesday              16
  7  07-06-2017  Thursday               32
  8  07-07-2017  Friday                 64
  9  07-08-2017  Saturday              128
 10  07-09-2017  Sunday                256
 11  07-10-2017  Monday                512
 12  07-11-2017  Tuesday             1,024
 13  07-12-2017  Wednesday           2,048
 14  07-13-2017  Thursday            4,096
 15  07-14-2017  Friday              8,192
 16  07-15-2017  Saturday           16,384
 17  07-16-2017  Sunday             32,768
 18  07-17-2017  Monday             65,536
 19  07-18-2017  Tuesday           131,072
 20  07-19-2017  Wednesday         262,144
 21  07-20-2017  Thursday          524,288
 22  07-21-2017  Friday          1,048,576
 23  07-22-2017  Saturday        2,097,152
 24  07-23-2017  Sunday          4,194,304
 25  07-24-2017  Monday          8,388,608
 26  07-25-2017  Tuesday        16,777,216
 27  07-26-2017  Wednesday      33,554,432
 28  07-27-2017  Thursday       67,108,864
 29  07-28-2017  Friday        134,217,728
 30  07-29-2017  Saturday      268,435,456
 31  07-30-2017  Sunday        536,870,912
 32  07-31-2017  Monday      1,073,741,824
Here are the steps I followed:
  • Create the table in cells A2:B32.
  • Format Column C to use a mono-space font such as Courier.
  • Enter the following formula into cell C2 and copy it down to cell C32:

    Code: Select all

    =RIGHT("  "&ROW(A2),3)&"  "&LEFT(TEXT(A2,"mm-dd-yyyy  dddd")&REPT(" ",40),21)&RIGHT(REPT(" ",20)&TEXT(B2,"#,###,###,##0"),16)
  • Copy cells C2:C32 into a text editor (like TexEdit on a Mac or Notepad on a PC) that uses a mono-space font.
  • Finalize the table in the text editor and then copy it into the Post a Reply window.

fundseeker
Posts: 632
Joined: Mon Dec 24, 2007 9:02 am

Re: Creating tables in Bogleheads.org forums

Post by fundseeker » Wed Jul 19, 2017 9:12 pm

That's impressive! I will give that a try, though I may need to learn more about Excel first. Thank you!

User avatar
patrick013
Posts: 1849
Joined: Mon Jul 13, 2015 7:49 pm

Re: Creating tables in Bogleheads.org forums

Post by patrick013 » Thu Jul 20, 2017 1:53 pm

Actually it takes a few steps.

First make your table or spreadsheet in Excel.
Set print area and export it as a .pdf
Then open or import it into Gimp or some other large graphic editor.
Perhaps crop it to size and save the final result to a .png file.
Upload it to tinypic or other graphic file service.
Post it to a forum message.

Example :
Image
Or :
http://myphotos.mypclinuxos.com/images/ ... ession.png
age in bonds, buy-and-hold, 10 year business cycle

Post Reply