Questions tagged [tilde]

The ~ (tilde) can have different meanings: it can be an operator, performing a bitwise negation on a binary number - all 1 bits are set to 0 and all 0 bits are set to 1. It can also simply be the tilde character itself, as used in Windows for shortening long path names.

171 questions
5
votes
1 answer

Using LaTex "~" symbol in Python using LaTeX

Please see the piece of the code I am using to produce an image. At the end, I want to write a text withing the image. There, i want to use "~" symbol using TeX rendering set through rc parameters. But, when I run the code, it doesn't even print the…
cat
  • 103
  • 2
  • 2
  • 8
5
votes
2 answers

R ggplot2 annotate with subscript and tilde

I'm trying to annotate a ggplot2 plot with a label that states the distribution for X1 ~ N(mu=10,sigma=3), where the 1 is meant to be subscript, like this: label1<-"X[1] ~ N( \U03bc = 10, \U03c3 = 3)" When I use label1 like…
MartineJ
  • 591
  • 5
  • 16
5
votes
1 answer

How to obtain tilde or approx symbol in gnuplot legend?

I want to use either tilde (~) or approximate symbol (in latex \approx) in the legend of my gnuplot. I am using epscairo terminal. I tried seting either: set encoding iso_8859_1 or set encoding utf8 and using different commands, for example \176 as…
nevermind
  • 129
  • 1
  • 7
5
votes
2 answers

Python Pandas Replace Special Character

For some reason, I cannot get this simple statement to work on the ñ. It seems to work on anything else but doesn't like that character. Any ideas? DF['NAME']=DF['NAME'].str.replace("ñ","n") Thanks
user3221876
  • 275
  • 2
  • 4
  • 7
4
votes
2 answers

Path with a folder named tilde(~) can't be recognized by load-file in emacs

I have a folder /var/~/. In config .emacs I wanna load some files from this folder. I try to use (load-file "/var/~/foobar.el"), but emacs alerts File error: Cannot open load file, ~/foobar.el. Furthermore I couldn't even open the files under this…
Ophiuchus Hahn
  • 145
  • 2
  • 12
4
votes
1 answer

Tilde-based Paths in Objective-C

In Objective-C, how do I go about converting tilde-based pathnames to full pathnames? That is, I'd like to convert from ~/sandbox to /Users/TheBobs/sandbox.
zanussi
  • 1,286
  • 2
  • 22
  • 29
4
votes
1 answer

Stop R from parsing ~ to user's home directory

I try to run the following script in R (minimized example): library(neuralnet) arrhythmia <- read.csv(file=".../arrhythmia-edited.csv", head=TRUE, sep=",") # create the first parameter for neuralnet formular # format like 'classification ~…
stfn
  • 105
  • 1
  • 4
4
votes
4 answers

Python os.getcwd() returns with tilde in the path. e.g. C:\MYFOLD~1\test

How can I get python to return the full pathname of C:\myfolderisafolder\test?
Brad Conyers
  • 1,161
  • 4
  • 15
  • 24
3
votes
2 answers

How to stop unwanted tilde character appearing in git bash windows?

How to stop unwanted tilde character appearing in git bash windows? I am using Git bash in windows 10. Facing an weird problem. Tilde character is automatically appearing in the bash window sometimes which is causing my normal workflow tedious. Why…
Sazzad Hissain Khan
  • 37,929
  • 33
  • 189
  • 256
3
votes
2 answers

How to Match Tilde-Delimited Data Using Regex

I have data like this: ~10~682423~15~Test Data~10~68276127~15~More Data~10~6813~15~Also Data~ I'm trying to use Notepad++ to find and replace the values within tag 10 (682423, 68276127, 6813) with zeroes. I thought the syntax below would work, but…
Jawann
  • 53
  • 1
  • 9
3
votes
2 answers

Why is psql inserting a tilde when I press any of the keys in the Home key cluster?

I'm using psql 8.2.3 on FreeBSD. Every time I press Insert, Home, Delete, End, Page Up or Page Down, a tilde (~) character is inserted instead of performing the expected function of the key. Why does this happen and how can I fix it?
cowgod
  • 8,626
  • 5
  • 40
  • 57
3
votes
1 answer

Rename to folder with tilde symbol

I know the method Directory.Move(source, destination) to rename a folder. But when I rename the desitnation folder with the ~ symbol at the begin, there is error. System.NotSupportedException: The given path's format is not supported. Here is my…
quyleanh
  • 63
  • 5
3
votes
2 answers

What does a function with this ~ mean? (e.g. function=f(~, x, y))

I am doing another coursera assignemnt, this time with aerial robotics. I have to program a pd controller using the matlab ode45 (ordinary diff. equation). And the file that has to contain this code gets called as follows: pd_controller(~, s, s_des,…
Andreas K.
  • 389
  • 4
  • 17
3
votes
1 answer

Tilde (~) Delimited File Read in SSIS

I'm trying to load a Tilde (~) delimited .DAT to SQL Server DB using SSIS. When I use a flat file source to read the file, I don't see the option of a ~ delimiter. I'm pasting a row from my file below: 7318~97836: LRX PAIN MONTHLY DX~001~ALL OTHER…
Triumph Spitfire
  • 663
  • 15
  • 38
3
votes
7 answers

NOT operation on integer value

I knew that ~ operator does NOT operation. But I could not make out the output of the following program (which is -65536). What exactly is happening? #include int main(void) { int b = 0xFFFF; printf("%d",~b); return 0; }
me_neo
  • 95
  • 9
1 2
3
11 12