Skip to main content

Questions tagged [table]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer
162 views

How do I get the physical address of the page table?

I was trying to get the physical address of the page table itself, but kept failing. The last option I'm going to try, is to modify the kernel code and simply print out the physical address whenever ...
Michael Jaemin Kim's user avatar
-2 votes
1 answer
223 views

Template for formatting output as a dynamic table in bash

I have a created a simple script which is using the ps aux command to give information for a process entered by a user, and presents the output in a table like format (something like the mysql shell ...
October's user avatar
  • 11
1 vote
3 answers
321 views

How to filter a table using awk

I was wondering how to filter a table with several columns based on a specific value in each of the columns of interest. I have this example here: Chr1 16644 0 0 1 1 ...
Assa Yeroslaviz's user avatar
0 votes
1 answer
2k views

Converting data in text file to csv tables

My data in a text file have the below format today HKL1234/2, R1B HKL1274/2, R4E HREF457-74, R1A I need to present this data in excel file in two different columns like below: Product ...
Dalea Kaldeby's user avatar
0 votes
1 answer
62 views

Do shells have a command equivalent of the "|" pipe symbol? I need something like that in Emacs org-mode tables

I like to construct commands which use the | pipe symbol in org tables and | symbol messes them up. Do bash et al have a text command that is the equivalent of the symbol? Are there alternative ways ...
vfclists's user avatar
  • 7,619
1 vote
4 answers
273 views

How do I use sed to print only a specific "table" in a text report file? [duplicate]

In a report file generated from Quartus, there are multiple "tables" like the following: +---------------------+ ; Section1 Title ; +---------------------+ Miscellaneous text +---------...
JohnR's user avatar
  • 13
1 vote
3 answers
604 views

How to find first occurrence of string in log file, set T/F value as variable, and record changes that occur

I'm not sure how to title this, but here's what I've got: A file with text like: [10:03:43] 10:03:35 22JUN22 ConUP CW1B1 T CW1B3 T CW1B5 T CW1B7 T [10:03:44] ...
ditch's user avatar
  • 9
0 votes
1 answer
92 views

How to use one table (ods) file as a base for another table file?

I have an accounting ledger table (.ods) file which should be the base for other table files. This table file should be the base for other table files such as: 2023.ods 2024.ods 2025.ods These are ...
searcher's user avatar
-5 votes
3 answers
9k views

How to transform bash output to bash table [closed]

My output after running a program in bash looks like this (two rows, : limiter, four columns of data) #003:BMW:11:36 #004:Audi:2:35 I would like to convert that to a bash table like this Number Car ...
Blaine44's user avatar
0 votes
1 answer
450 views

Sorting a table with a non-newline record separator in bash

I have a table that looks like 'a;b;f|d;e;c|g;h' which I wish to sort by the third column. The output should be 'g;h|d;e;c|a;b;f' If I were to use the standard delimiters whitespace and newline then ...
fuumind's user avatar
  • 449
0 votes
1 answer
34 views

Pasting files and concatating files together

I have various years and months of data for numerous site locations. I have computed the average for all months for each needed year. Each Month/Year has its own its own file. Not all sites have data ...
stormctr2's user avatar
0 votes
1 answer
128 views

Transpose large table

guys I am sorry if this has been asked before, but I will give it a try. I have a table (tab delimited text file) that is formatted like this Species1 Species2 Species3 Gene 1 Value ...
MartinOdegaard's user avatar
0 votes
1 answer
633 views

shell: combining several tables [duplicate]

Within same workdir I have several 2 column tables (with | separators between the columns) containing the same number of lines and share the order within the first column . Here is an example for two ...
user3470313's user avatar
-1 votes
2 answers
921 views

Awk to convert TSV table into grid table [closed]

I want to convert a text table with tab as delimiter (i.e., basically a TSV file) to a grid table with lines on all borders (inside and outside) and text wrapping. The below is the input TrackId ...
iconluv's user avatar
  • 33
1 vote
2 answers
175 views

Merge rows using common values in any column

I have a tab-delimited file like shown below, and would like to merge the rows based on matches in any of the columns. The number of columns are usually 2, but could vary in some cases and be 3. ...
Susheel Busi's user avatar
-2 votes
2 answers
45 views

Text to table with v lookup [closed]

I have file as below FileName:File1.txt Can we get the format as below table
Vicks87s's user avatar
3 votes
2 answers
2k views

BASH: AWK pivot CSV into desired table

I have been struggling with pivoting .csv file into desired table format using bash. My file o/p: $ cat finalcount.csv state,status,count NW,CONGESTED,11 NW,CLEARED,9 ACT,CLEARED,7 ACT,CONGESTED,7 ...
user8421137's user avatar
-2 votes
1 answer
37 views

Is it possible to sort out similar rows in a table and put the number in a column? [duplicate]

I have this table gene 5 5 5 gene 4 4 3 gene 5 5 5 gene 1 4 5 and I would like to have the following, gene 5 5 5 2 gene 4 4 3 1 gene 1 4 5 1 so in the last column ...
Mark's user avatar
  • 29
0 votes
1 answer
54 views

Merging two .csv tables one with header other - not

I need to merge two .csv tables, one that contains the following info with NO HEADER: gene0 ABCD gene1 xyz gene2 1234 ..etc Another table has a header and information like that: gene_id ...
Mark's user avatar
  • 29
-2 votes
1 answer
729 views

How can I scramble a text file table, with a table

I have a table. The column order must not be changed. And the values should be kept. Name Age size Code Abel 10 S A Bjorn 20 M B Casimir 30 L C Dennis 40 XL D I don't just ...
Thomas Richter's user avatar
0 votes
3 answers
879 views

How to calculate the sum of bytes in a column?

I have this table below, how can I calculate the sum of bytes for records in Nov only? for example below I want to find rows in Nov then sum the numbers in column4 relevant to Nov only? how I can do ...
Kenan's user avatar
  • 5
2 votes
1 answer
2k views

Awk for merging multiple files with common column

I have a question concerning awk command in unix to merge multiple tables with a common value Tab1 Geneid Chr Start End Strand Length Sample_1 ENSG00000278267 1 17369 17436 - 68 0 ...
Nicolas's user avatar
  • 23
2 votes
1 answer
794 views

Manually set NX bit of specific PTE

On Ubuntu with kernel 4.16.7 I am writing a custom system call and, I want to set the NX bit of a specific Page Table Entry. So far I have this piece of code, where I am doing a page table walk to get ...
Mar Tsan's user avatar
0 votes
1 answer
342 views

How to add a text file content to the next column of an existing table

How do a add a new line to an existing .txt file, that consists of a text string, a tab, and a value of another text file? Precisely, I have a text file test1.txt that looks like this: A B and a ...
Ljubo's user avatar
  • 1
1 vote
0 answers
1k views

Referencing dynamically created table names in Create statement written in shell script

I need to write a script to automatically generate a month end report. The generation process involved creating tables in database and then accessing them later in the same script to create another ...
A.Bhargava's user avatar
1 vote
1 answer
1k views

Why some tables contains only part of chains in iptables?

I am reading some tutorial on the webpage iptables tutorial. There are five chains in iptables. PREROUTING chain OUTPUT chain FORWARD chain INPUT chain POSTROUTING chain And there are four tables in ...
showkey's user avatar
  • 395
0 votes
2 answers
248 views

Changing from row to column with Shell script command

I'm using UNIX language to extract my files. I used this command to extract it: value_1=$(cat tmp.csv | head -1001 | cut -f 3-6 -d','> tmp1.csv) value_2=$(cat tmp.csv | head -2002 | tail -1001 | ...
ahmad adilah's user avatar
2 votes
4 answers
249 views

Extracting lines appeared consecutively for 3 times or more in Linux

I have a table in Linux : A 0 A 0 A 0 B 0 B 1 B 0 B 1 B 0 I want to extract lines appeared consecutively for 3 times or more. My expected output is : A 0 Actually, 3 times or more is just a ...
Johnny Tam's user avatar
1 vote
1 answer
5k views

printing row-based data in a table format on Linux

I have the below data in a file: col1 col2 col3 subcol1 subcol2 subcol3 subcol4 subcol5 subcol6 col4 subcol7 subcol8 subcol9 subcol10 subcol11 subcol2 The ...
wazza's user avatar
  • 149
1 vote
2 answers
269 views

Extracting quoted and labelled data from a given column

I have a large GTF file, like below: # ./stringtie -p 4 -G /home/humangenome_hg19/homo_gtf_file.gtf -o strAD1_as/transcripts.gtf -l strAD1 /home/software/star-2.5.2b/bin/Linux_x86_64/mapA1Aligned....
Mary's user avatar
  • 129
0 votes
1 answer
127 views

Edit value in table

Need to set a function which receives a username, location in the table and the new value to set. the table set is user:value1:value2:value3 I realize how I can do the replace using awk '{gsub... ...
Itay Gurvich's user avatar
4 votes
3 answers
22k views

Bash output array in table

I'm quite new at bash and I am trying to learn it by creating some small scripts. I created a small script to look up the DNS entry for multiple domains at the same time. The domains are given as ...
Matt Backslash's user avatar
3 votes
3 answers
2k views

Delete columns that sum to zero

I have a numeric table, that is all cells have numbers. It is a tab-delimited file, with non-numeric headers and row names. I need to delete all columns that add up zero. I would like to keep the ...
fibar's user avatar
  • 41
1 vote
1 answer
2k views

Adding column to a table by concatenating values from other columns

I have several csv table as follow: YEAR;MONTH;DAY;RES1;RES2 1971;1;1;1206.1;627 1971;1;2;1303.4;654.3 1971;1;3;1248.9;662 1971;1;4;1188.8;666.8 From this I would like to create a new column that ...
steve's user avatar
  • 548
0 votes
1 answer
454 views

Calculate average values for each day over multiple years

I have some "CSV" data (actually using ; as a delimiter) having a row for every day from 1971-01-01 through 2099-12-31 (a span of 2099−1971=128 years). The data are organized as follows: YEAR;MONTH;...
steve's user avatar
  • 548
1 vote
2 answers
8k views

Change header using sed or awk

I have different file for which I would like to change the header. Currently the tables are as follow: MONTH GFDL.ESM2M_ECOMAG GFDL.ESM2M_HYPE 1 3546.21855483871 2345.11127781945 I would like to ...
steve's user avatar
  • 548
1 vote
1 answer
874 views

Paste different csv files

I have a bunch of input csv files (delimited with semi-colon ";" having the following format YEAR;MONTH;DAY;RES1FILE1;RES2FILE1;RES3FILE1 1901;01;01;101;154;169 1901;01;02;146;174;136 The number of ...
steve's user avatar
  • 548
1 vote
1 answer
238 views

space in time column causing problem in formatting html file in script

I am in the process of creating an automated mail where in the body of the mail data should be displayed in a table format. I did some extent generate a table format in the body of mail, but I am ...
megha's user avatar
  • 11
0 votes
1 answer
79 views

reformat values in a table

I have some tables, in which I need to replace several values. I have different commands sed and tr that work just fine when I apply them to a single file. But somehow, when I want to build a loop ...
steve's user avatar
  • 548
0 votes
1 answer
616 views

Replace value in a table

I have some tables for which I need to replace a field that has a random position in each table. For information, the table are semicolon separated fields and I would like to replace the field "datum"...
steve's user avatar
  • 548
0 votes
1 answer
93 views

Table - Replace values of a column

I have several tables (tab separated) in which the first column is as follow: MONTH 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 I would like to replace those values by the actual ...
steve's user avatar
  • 548
0 votes
3 answers
49 views

Reformat table - Number of digits

I have some tables were the numbers have too much digits; as follow: MONTH A1 A2 A3 ...... 1 1.54564468 2.48949 6.4984984 ..... Is there a way, using unix, to reformat the table in the following ...
steve's user avatar
  • 548
0 votes
3 answers
4k views

How can I use a triple slash as a delimiter with cut?

I have a table in which each entry looks something like, coagulation factor VIII-associated 1 /// coagulation factor VIII-associated 2 /// coagulation factor VIII-associated 3 I would like to use ...
Atticus29's user avatar
  • 143
9 votes
3 answers
4k views

Issue with column command and color escape codes

I'm colorizing the header of a table formatted with column -ts $'\t' Works well without color codes, but when I add color codes to the first line column doesn't properly align the output. Without ...
Niklas Berglund's user avatar
1 vote
1 answer
632 views

Matching 2 main columns between files; and paste other columns into the output file when those main columns match. Keep row size of 1st file intact

This is a follow-up question to my previous question asked about 24 hours ago: Matching two main columns at the same time between files, and paste supplementary columns into the output file when those ...
Noobie123's user avatar
1 vote
1 answer
386 views

Replace values in a table

I have a table (ascii format with space delimiter), as follow: 1 1 1900 111 1 2 1900 121 1 3 1900 145 1 4 1900 1.45e 07 1 5 1900 5.21e 25 1 6 1900 152 I would like, that if there is a fifth column (...
steve's user avatar
  • 548
2 votes
4 answers
150 views

Move files/table following selection criteria

Considering a variable a describing temperature series for the city a. I have 9 directories (a1, a2, a3, a4, a5, a6, a7, a8, a9) each of them containing a table (respectively a1.txt, a2.txt, a3.txt, ...
steve's user avatar
  • 548
1 vote
1 answer
1k views

Text extraction from HTML page

I am using xidel command to extract text from HTML page. Here is my code xidel http://www.ip-adress.com/ip_tracer/8.8.8.8 --extract "<table> <tbody> <tr> <td> <...
Swatesh Pakhare's user avatar
1 vote
0 answers
699 views

extracting text from HTML

I have this page. I want to extract text from html page, particularly table heading (th) and table data (td). For example: Country: United States (US),State: California where th = Country and td = ...
Swatesh Pakhare's user avatar
4 votes
3 answers
995 views

Leap year - extrapolating value

I have some tables (table.txt) as follow: YEAR MONTH DAY RES 1971 1 1 1345 1971 1 2 1265 1971 1 3 1167 The length of each time series goes from 1.1.1971 until 31.12.2099. ...
steve's user avatar
  • 548