Set column widthMy table doesn't fit; what are my options?How to format table with long column head...

A ​Note ​on ​N!

Initiative: Do I lose my attack/action if my target moves or dies before my turn in combat?

Phrase for the opposite of "foolproof"

Relationship between strut and baselineskip

"Whatever a Russian does, they end up making the Kalashnikov gun"? Are there any similar proverbs in English?

a sore throat vs a strep throat vs strep throat

Is Diceware more secure than a long passphrase?

On The Origin of Dissonant Chords

What term is being referred to with "reflected-sound-of-underground-spirits"?

Why does nature favour the Laplacian?

Is there really no use for MD5 anymore?

How to not starve gigantic beasts

How did Captain America manage to do this?

Aligning equation numbers vertically

Was there a Viking Exchange as well as a Columbian one?

What happens to Mjolnir (Thor's hammer) at the end of Endgame?

Implications of cigar-shaped bodies having rings?

How exactly does Hawking radiation decrease the mass of black holes?

Elements other than carbon that can form many different compounds by bonding to themselves?

Can I criticise the more senior developers around me for not writing clean code?

Minor Revision with suggestion of an alternative proof by reviewer

Why didn't the Space Shuttle bounce back into space as many times as possible so as to lose a lot of kinetic energy up there?

Pre-plastic human skin alternative

Which big number is bigger?



Set column width


My table doesn't fit; what are my options?How to format table with long column head entries?Latex: rowcolor in tabular not respecting table widthTabular and grid typesettingSet column width to pointtabu package - gaps in vertical linesHorizontal lines in nested tabular environmentHow to create a table with fixed-width cells and use cellcolor and multicolumn to create time bars? Or: How to substitute ganttbar with tabular?Having trouble understanding the tabular environmentHow to set longtable width to text width so that the text in cell wraps around automatically?Set specified width for column













0















Hi I have the following table. Is there a way to set the width of the column. I want to minimize the column width so that it could fit my journal template.



documentclass{article}
usepackage{amsmath}
usepackage{tabular}

begin{document}
begin{table}[ht!]
caption{Sensitivity Analysis of the Parameters in the Inventory model}
label{tab:my tab}
begin{tabular}{|lcc{1cm}||cccccc|}
hline
multirow{3}{*}{Parameters}&
multirow{3}{*}{Values}&
multirow{3}{*}{% Change}&
multicolumn{6}{|c|}{Change in}\ cline{4-9}
&&&$T$&$t_1$&$TVC$&$S$&$P$&$Q$ \ hline
end{tabular}
end{document}









share|improve this question
















bumped to the homepage by Community 22 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
















  • Do not write text between $...$. If you want italicized use textit{...}. And to set the width of a column you have to use p{1cm}, not c{1cm}.

    – Phelype Oleinik
    Jun 30 '18 at 19:35











  • @PhelypeOleinik sorry i have edited that. so do you mean that the command should be begin{tabular}{|p{1cm}p{1cm}p{1cm}||cccccc|} ?

    – shahrina ismail
    Jun 30 '18 at 20:02






  • 1





    If you want to make the first three columns with 1 cm wide, yes. But LaTeX builds tables so that the width of the column is adjusted to the contents of the table. It would help if you showed us the journal template so that we can make it fit the margins. Meanwhile you can take a look at this thread to find some methods to reduce the size of tables.

    – Phelype Oleinik
    Jun 30 '18 at 20:09
















0















Hi I have the following table. Is there a way to set the width of the column. I want to minimize the column width so that it could fit my journal template.



documentclass{article}
usepackage{amsmath}
usepackage{tabular}

begin{document}
begin{table}[ht!]
caption{Sensitivity Analysis of the Parameters in the Inventory model}
label{tab:my tab}
begin{tabular}{|lcc{1cm}||cccccc|}
hline
multirow{3}{*}{Parameters}&
multirow{3}{*}{Values}&
multirow{3}{*}{% Change}&
multicolumn{6}{|c|}{Change in}\ cline{4-9}
&&&$T$&$t_1$&$TVC$&$S$&$P$&$Q$ \ hline
end{tabular}
end{document}









share|improve this question
















bumped to the homepage by Community 22 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.
















  • Do not write text between $...$. If you want italicized use textit{...}. And to set the width of a column you have to use p{1cm}, not c{1cm}.

    – Phelype Oleinik
    Jun 30 '18 at 19:35











  • @PhelypeOleinik sorry i have edited that. so do you mean that the command should be begin{tabular}{|p{1cm}p{1cm}p{1cm}||cccccc|} ?

    – shahrina ismail
    Jun 30 '18 at 20:02






  • 1





    If you want to make the first three columns with 1 cm wide, yes. But LaTeX builds tables so that the width of the column is adjusted to the contents of the table. It would help if you showed us the journal template so that we can make it fit the margins. Meanwhile you can take a look at this thread to find some methods to reduce the size of tables.

    – Phelype Oleinik
    Jun 30 '18 at 20:09














0












0








0








Hi I have the following table. Is there a way to set the width of the column. I want to minimize the column width so that it could fit my journal template.



documentclass{article}
usepackage{amsmath}
usepackage{tabular}

begin{document}
begin{table}[ht!]
caption{Sensitivity Analysis of the Parameters in the Inventory model}
label{tab:my tab}
begin{tabular}{|lcc{1cm}||cccccc|}
hline
multirow{3}{*}{Parameters}&
multirow{3}{*}{Values}&
multirow{3}{*}{% Change}&
multicolumn{6}{|c|}{Change in}\ cline{4-9}
&&&$T$&$t_1$&$TVC$&$S$&$P$&$Q$ \ hline
end{tabular}
end{document}









share|improve this question
















Hi I have the following table. Is there a way to set the width of the column. I want to minimize the column width so that it could fit my journal template.



documentclass{article}
usepackage{amsmath}
usepackage{tabular}

begin{document}
begin{table}[ht!]
caption{Sensitivity Analysis of the Parameters in the Inventory model}
label{tab:my tab}
begin{tabular}{|lcc{1cm}||cccccc|}
hline
multirow{3}{*}{Parameters}&
multirow{3}{*}{Values}&
multirow{3}{*}{% Change}&
multicolumn{6}{|c|}{Change in}\ cline{4-9}
&&&$T$&$t_1$&$TVC$&$S$&$P$&$Q$ \ hline
end{tabular}
end{document}






tables






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Jun 30 '18 at 19:59







shahrina ismail

















asked Jun 30 '18 at 19:27









shahrina ismailshahrina ismail

594217




594217





bumped to the homepage by Community 22 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.







bumped to the homepage by Community 22 mins ago


This question has answers that may be good or bad; the system has marked it active so that they can be reviewed.















  • Do not write text between $...$. If you want italicized use textit{...}. And to set the width of a column you have to use p{1cm}, not c{1cm}.

    – Phelype Oleinik
    Jun 30 '18 at 19:35











  • @PhelypeOleinik sorry i have edited that. so do you mean that the command should be begin{tabular}{|p{1cm}p{1cm}p{1cm}||cccccc|} ?

    – shahrina ismail
    Jun 30 '18 at 20:02






  • 1





    If you want to make the first three columns with 1 cm wide, yes. But LaTeX builds tables so that the width of the column is adjusted to the contents of the table. It would help if you showed us the journal template so that we can make it fit the margins. Meanwhile you can take a look at this thread to find some methods to reduce the size of tables.

    – Phelype Oleinik
    Jun 30 '18 at 20:09



















  • Do not write text between $...$. If you want italicized use textit{...}. And to set the width of a column you have to use p{1cm}, not c{1cm}.

    – Phelype Oleinik
    Jun 30 '18 at 19:35











  • @PhelypeOleinik sorry i have edited that. so do you mean that the command should be begin{tabular}{|p{1cm}p{1cm}p{1cm}||cccccc|} ?

    – shahrina ismail
    Jun 30 '18 at 20:02






  • 1





    If you want to make the first three columns with 1 cm wide, yes. But LaTeX builds tables so that the width of the column is adjusted to the contents of the table. It would help if you showed us the journal template so that we can make it fit the margins. Meanwhile you can take a look at this thread to find some methods to reduce the size of tables.

    – Phelype Oleinik
    Jun 30 '18 at 20:09

















Do not write text between $...$. If you want italicized use textit{...}. And to set the width of a column you have to use p{1cm}, not c{1cm}.

– Phelype Oleinik
Jun 30 '18 at 19:35





Do not write text between $...$. If you want italicized use textit{...}. And to set the width of a column you have to use p{1cm}, not c{1cm}.

– Phelype Oleinik
Jun 30 '18 at 19:35













@PhelypeOleinik sorry i have edited that. so do you mean that the command should be begin{tabular}{|p{1cm}p{1cm}p{1cm}||cccccc|} ?

– shahrina ismail
Jun 30 '18 at 20:02





@PhelypeOleinik sorry i have edited that. so do you mean that the command should be begin{tabular}{|p{1cm}p{1cm}p{1cm}||cccccc|} ?

– shahrina ismail
Jun 30 '18 at 20:02




1




1





If you want to make the first three columns with 1 cm wide, yes. But LaTeX builds tables so that the width of the column is adjusted to the contents of the table. It would help if you showed us the journal template so that we can make it fit the margins. Meanwhile you can take a look at this thread to find some methods to reduce the size of tables.

– Phelype Oleinik
Jun 30 '18 at 20:09





If you want to make the first three columns with 1 cm wide, yes. But LaTeX builds tables so that the width of the column is adjusted to the contents of the table. It would help if you showed us the journal template so that we can make it fit the margins. Meanwhile you can take a look at this thread to find some methods to reduce the size of tables.

– Phelype Oleinik
Jun 30 '18 at 20:09










1 Answer
1






active

oldest

votes


















0















  • i suspect, that your document has two columns

  • prescribe column width, which is smaller than width of cells content can lead to new problems (you can't always relay on hyphenation)


  • a solution can be use tabular* with prescibe table width equal column width, set tabcolsep to 3pt and use @{extracolsep{fill}}:



    documentclass[twocolumn]{article} % <---
    usepackage{amsmath}
    usepackage{multirow} % <---

    %---------------- show page layout. don't use in a real document!
    usepackage{showframe}
    renewcommandShowFrameLinethickness{0.15pt}
    renewcommand*ShowFrameColor{color{red}}
    %---------------------------------------------------------------%
    usepackage{lipsum}

    begin{document}
    lipsum[1]
    begin{table}[htb]
    small % <---
    setlengthtabcolsep{3pt} % <---
    caption{Sensitivity Analysis of the Parameters in the Inventory model}
    label{tab:my tab}
    begin{tabular*}{linewidth}{@{extracolsep{fill}} % <---
    |lcc||cc cc cc|}
    hline
    multirow{2}{*}{textit{Parameters}} &
    multirow{2}{*}{textit{Values}} &
    multirow{2}{*}{textit{% Change}} &
    multicolumn{6}{c|}{Change in} \ cline{4-9}
    & & & $T$ & $t_1$ & $TVC$ & $S$ & $P$ & $Q$ \ hline
    end{tabular*}
    end{table}
    lipsum[2-8]
    end{document}



which gives:



enter image description here



(red lines indicate text borders)






share|improve this answer


























    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "85"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: false,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f438704%2fset-column-width%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0















    • i suspect, that your document has two columns

    • prescribe column width, which is smaller than width of cells content can lead to new problems (you can't always relay on hyphenation)


    • a solution can be use tabular* with prescibe table width equal column width, set tabcolsep to 3pt and use @{extracolsep{fill}}:



      documentclass[twocolumn]{article} % <---
      usepackage{amsmath}
      usepackage{multirow} % <---

      %---------------- show page layout. don't use in a real document!
      usepackage{showframe}
      renewcommandShowFrameLinethickness{0.15pt}
      renewcommand*ShowFrameColor{color{red}}
      %---------------------------------------------------------------%
      usepackage{lipsum}

      begin{document}
      lipsum[1]
      begin{table}[htb]
      small % <---
      setlengthtabcolsep{3pt} % <---
      caption{Sensitivity Analysis of the Parameters in the Inventory model}
      label{tab:my tab}
      begin{tabular*}{linewidth}{@{extracolsep{fill}} % <---
      |lcc||cc cc cc|}
      hline
      multirow{2}{*}{textit{Parameters}} &
      multirow{2}{*}{textit{Values}} &
      multirow{2}{*}{textit{% Change}} &
      multicolumn{6}{c|}{Change in} \ cline{4-9}
      & & & $T$ & $t_1$ & $TVC$ & $S$ & $P$ & $Q$ \ hline
      end{tabular*}
      end{table}
      lipsum[2-8]
      end{document}



    which gives:



    enter image description here



    (red lines indicate text borders)






    share|improve this answer






























      0















      • i suspect, that your document has two columns

      • prescribe column width, which is smaller than width of cells content can lead to new problems (you can't always relay on hyphenation)


      • a solution can be use tabular* with prescibe table width equal column width, set tabcolsep to 3pt and use @{extracolsep{fill}}:



        documentclass[twocolumn]{article} % <---
        usepackage{amsmath}
        usepackage{multirow} % <---

        %---------------- show page layout. don't use in a real document!
        usepackage{showframe}
        renewcommandShowFrameLinethickness{0.15pt}
        renewcommand*ShowFrameColor{color{red}}
        %---------------------------------------------------------------%
        usepackage{lipsum}

        begin{document}
        lipsum[1]
        begin{table}[htb]
        small % <---
        setlengthtabcolsep{3pt} % <---
        caption{Sensitivity Analysis of the Parameters in the Inventory model}
        label{tab:my tab}
        begin{tabular*}{linewidth}{@{extracolsep{fill}} % <---
        |lcc||cc cc cc|}
        hline
        multirow{2}{*}{textit{Parameters}} &
        multirow{2}{*}{textit{Values}} &
        multirow{2}{*}{textit{% Change}} &
        multicolumn{6}{c|}{Change in} \ cline{4-9}
        & & & $T$ & $t_1$ & $TVC$ & $S$ & $P$ & $Q$ \ hline
        end{tabular*}
        end{table}
        lipsum[2-8]
        end{document}



      which gives:



      enter image description here



      (red lines indicate text borders)






      share|improve this answer




























        0












        0








        0








        • i suspect, that your document has two columns

        • prescribe column width, which is smaller than width of cells content can lead to new problems (you can't always relay on hyphenation)


        • a solution can be use tabular* with prescibe table width equal column width, set tabcolsep to 3pt and use @{extracolsep{fill}}:



          documentclass[twocolumn]{article} % <---
          usepackage{amsmath}
          usepackage{multirow} % <---

          %---------------- show page layout. don't use in a real document!
          usepackage{showframe}
          renewcommandShowFrameLinethickness{0.15pt}
          renewcommand*ShowFrameColor{color{red}}
          %---------------------------------------------------------------%
          usepackage{lipsum}

          begin{document}
          lipsum[1]
          begin{table}[htb]
          small % <---
          setlengthtabcolsep{3pt} % <---
          caption{Sensitivity Analysis of the Parameters in the Inventory model}
          label{tab:my tab}
          begin{tabular*}{linewidth}{@{extracolsep{fill}} % <---
          |lcc||cc cc cc|}
          hline
          multirow{2}{*}{textit{Parameters}} &
          multirow{2}{*}{textit{Values}} &
          multirow{2}{*}{textit{% Change}} &
          multicolumn{6}{c|}{Change in} \ cline{4-9}
          & & & $T$ & $t_1$ & $TVC$ & $S$ & $P$ & $Q$ \ hline
          end{tabular*}
          end{table}
          lipsum[2-8]
          end{document}



        which gives:



        enter image description here



        (red lines indicate text borders)






        share|improve this answer
















        • i suspect, that your document has two columns

        • prescribe column width, which is smaller than width of cells content can lead to new problems (you can't always relay on hyphenation)


        • a solution can be use tabular* with prescibe table width equal column width, set tabcolsep to 3pt and use @{extracolsep{fill}}:



          documentclass[twocolumn]{article} % <---
          usepackage{amsmath}
          usepackage{multirow} % <---

          %---------------- show page layout. don't use in a real document!
          usepackage{showframe}
          renewcommandShowFrameLinethickness{0.15pt}
          renewcommand*ShowFrameColor{color{red}}
          %---------------------------------------------------------------%
          usepackage{lipsum}

          begin{document}
          lipsum[1]
          begin{table}[htb]
          small % <---
          setlengthtabcolsep{3pt} % <---
          caption{Sensitivity Analysis of the Parameters in the Inventory model}
          label{tab:my tab}
          begin{tabular*}{linewidth}{@{extracolsep{fill}} % <---
          |lcc||cc cc cc|}
          hline
          multirow{2}{*}{textit{Parameters}} &
          multirow{2}{*}{textit{Values}} &
          multirow{2}{*}{textit{% Change}} &
          multicolumn{6}{c|}{Change in} \ cline{4-9}
          & & & $T$ & $t_1$ & $TVC$ & $S$ & $P$ & $Q$ \ hline
          end{tabular*}
          end{table}
          lipsum[2-8]
          end{document}



        which gives:



        enter image description here



        (red lines indicate text borders)







        share|improve this answer














        share|improve this answer



        share|improve this answer








        edited Jun 30 '18 at 22:06

























        answered Jun 30 '18 at 20:15









        ZarkoZarko

        131k870170




        131k870170






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to TeX - LaTeX Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f438704%2fset-column-width%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            El tren de la libertad Índice Antecedentes "Porque yo decido" Desarrollo de la...

            Castillo d'Acher Características Menú de navegación

            Connecting two nodes from the same mother node horizontallyTikZ: What EXACTLY does the the |- notation for...