Questions tagged [subscript]

A subscript is a number, figure, symbol, or indicator that is smaller than the normal line of type and is set slightly below the baseline.

subscript
Filter by
Sorted by
Tagged with
2 votes
1 answer
768 views

Print text with subscripts (programatically) to R console

I'm using R to balance some complex chemical equations and would like to print these equations including subscripts to the console as the code runs. I've seen some answers posted, most of which are ...
Gautam's user avatar
  • 2,651
2 votes
1 answer
598 views

How can I add a subscript to my axis label when using persp3D function in R?

I am trying to define my z-axis label as R0 in plot3D, below are my code, I am using expression for my zlab, but I get the result as in the image attached here. library(plot3D) lambda <- 1/12 ...
Ella Taib's user avatar
-2 votes
2 answers
111 views

Convert subscript function from Objective C to Swift

I am trying to convert some Objective C code to Swift and can't manage to do it right with subscripting. This is the method I am trying to migrate to Swift: - (NSArray *)rangesOfSubstringAlphaNumeric:...
Bogdan's user avatar
  • 412
0 votes
1 answer
603 views

Python and matplotlib: Equal vertical spacing of superscript and subscript characters (using Arial) in a plot's legend

With my last post in mind, I need some more help with matplotlib graphics and fonts. With the friendly help of ImportanceOfBeingErnest, I was able to create plots in Python, but superscript characters ...
TeXnician's user avatar
0 votes
0 answers
40 views

How to overcome this error? Attempted to access U(2,0); index must be a positive integer or logical [duplicate]

I am making a program that implements the Gauss-Seidel method for the Poisson equation. Here the error occurs due to zeros and negative values in subscripts. Will you please guide me on how to ...
Zuhaa Naz's user avatar
-1 votes
1 answer
264 views

Creating a subscript c in python text

I have made some graphs in matplotlib that have a omega with a subscript of b and c. Now i am in the process of creating the buttons to display these plots in tkinter and i was going to use the simple ...
Sean Powell's user avatar
0 votes
1 answer
116 views

R: Subscripted assignments not overwriting values, or changing all values (halfway figured out)

I have had a problem in my R code that comes up from time to time, where I will try to overwrite values of a variable using a subscripted assignment, and some/all of the values do not get overwritten. ...
TiredSquirrel's user avatar
1 vote
1 answer
27 views

Wanting to add a bool subscript to SKSpriteNode in swift so that I can toggle it on and off?

I'm wanting to be able to toggle on and off a bool var (isActive) on a SKSpriteNode. for example. someNode.isActive.toggle() I'm sure its simple but for some reason it is escaping me right now. I'...
Zbud68's user avatar
  • 119
7 votes
1 answer
906 views

Swift get vs _read

What's the difference between the following 2 subscripts? subscript(position: Int) { get { ... } } subscript(position: Int) { _read { ... } }
Wowbagger and his liquid lunch's user avatar
2 votes
3 answers
2k views

Adding subscript formatting to all numbers in a string

I'm trying to write a simple script that iterates through an input string and converts all numbers in the string to subscripted numbers. Here is my latest attempt that iterates over an input string ...
frozen5032's user avatar
3 votes
2 answers
213 views

How to shift one specific legend label with subscript slightly downwards?

I've generated a subscript in a legend label with expression() that shifts the entire label slightly upward and looks lousy (the red one in the middle). plot(1:10, type="l") curve(x^2, col=2, add=...
jay.sf's user avatar
  • 67.9k
3 votes
2 answers
6k views

Swift: Dictionary of Dicitionaries, cannot get subscript

I've looked at other subscript issues here and I don't think they match my problem. I have a dictionary of dictionaries - Dictionary[String:Dictionary[String:String]] In an extension I want to loop ...
MartianTribe's user avatar
0 votes
2 answers
102 views

same subscript code, when building it with two Separate lines it's working fine, when building it with one line of code, im getting an error , why?

I've add two pictures of my code , that explain both Scenarios at the first scenario the subscript work exactly like its supposed to work, with Two lines of code at the secound scenario , the code ...
yehudshe's user avatar
1 vote
0 answers
300 views

Excel Macro Err 9 - Subscript Out of Range - Error on Run but not when stepping through (f8)

I have written a VBA code to step through a selection of hyperlinks and grab data from each file. On the 2nd pass through the loop (when I run the macro), I get an err 9 - subscript out of range. ...
Matthew Stockton's user avatar
1 vote
0 answers
49 views

how to add subscript in asp boundfield header text

I want headername to be CO2 with 2 as subscript this is my code. <asp:BoundField DataField="CO2" HeaderText="CO2" /> so far i tried <asp:BoundField DataField="CO2" HeaderText="CO<sub&...
wheezay's user avatar
  • 101
4 votes
2 answers
2k views

How to display text with subscripts or superscripts in the Title Bar?

I would like to be able to show subscripted text in the Title Bar of a Windows Form or WPF Window. The reason for this is simple. Our project team has written a molecule editor: Instead of ...
deadlyvices's user avatar
2 votes
2 answers
2k views

Insert specific unicode symbols inside values of data.frame variable

In my data.frame I would like to add two variables, "A" and "B", whose values contain respectively an n with the i subscript and an n with the s subscript. As I have understood so far, it's not ...
nd091680's user avatar
  • 605
3 votes
2 answers
179 views

Subscript vs. Superscript conflict

Background: I'm trying to write a module to concatenate strings with it's formatting. Therefor I'm looking in all Font properties that could matter, including Subscript and Superscript. Sample Data: ...
JvdV's user avatar
  • 73.6k
0 votes
1 answer
626 views

Correct display of chemical formulae in ggplot axis category labels

I'm plotting a data set with chemical formulae as categories, and values associated with each: data <- data.frame(compound = factor(c("SiO[2]", "Al[2]O[3]", "CaO")), value = rnorm(...
TimM's user avatar
  • 109
1 vote
2 answers
568 views

How can I use Unicode in Turbo C++?

How can I use Unicode symbols in Turbo C++? I particularly want to superscript and subscript symbols. I must use the outdated Turbo C++ as this is what my school provides and I have to use this for my ...
user600016's user avatar
-1 votes
2 answers
185 views

Swift: simple way to get the first leaf of multidimensional array

Considering a non-empty multidimensional array that has no empty subarrays in it, how can I get the first leaf of it? Currently, I'm using the following construct: let multidimensional = [[[[[[...
Richard Topchii's user avatar
1 vote
2 answers
74 views

How to understand the error "subscipts out of bound", when indexing a column matrix with a matrix

Consider the following code example: The objective is to replace the indices in mymatrix with the corresponding values in mypoints. # example 1--------------------------------------------- mymatrix ...
clp's user avatar
  • 1,316
1 vote
1 answer
70 views

Find and select multiple cells within a worksheet

I am new to writing macros and have search everywhere for a solution to my problem with no luck, so I'm hoping for some help here. I have an Excel spreadsheet containing multiple calculation which ...
THStroemkjaer's user avatar
0 votes
1 answer
337 views

Subscripting letters in complex ggplot2 title

I want to subscript letters in a title that includes the word "in" in the title and it's proving to be quite the headache. I've looked at this thread and tried to translate it for my purposes but have ...
Joss Leehan's user avatar
0 votes
1 answer
121 views

Subscript out of range when copying range to another workbook

I am writing a reporting system where the user fills out a form and a form button runs a macro to save the file with a name based on several fields including a timestamp. All the data is is also on a ...
Pete Luxford's user avatar
1 vote
1 answer
352 views

Helvetica does not support subsrcipt numbers

i'm currently working with TCPDF. So far, so good, but I have to use subscript numbers like ₂ in CO₂. Unfortunately, helvetica (provided in TCPDF) doesn't support them, it'll end up in ? in CO?. ...
FryingPan's user avatar
  • 101
0 votes
1 answer
2k views

Can I override subscript in swift? [duplicate]

I want to do validity check and return appropriate value in array in swift, like below function objectFromArr(at:). var arr = [10, 20, 30, 40] func objectFromArr(at: Int) -> Int? { return at &...
strawnut's user avatar
  • 359
0 votes
1 answer
113 views

How to put a superscript right after a subscript that is not for the subscript

I am trying to make a label that has a superscript right after a subscript but I don't want the superscript as part of the subscript. I have tried and either got the superscript as part of the ...
Michael's user avatar
  • 17
1 vote
1 answer
346 views

'subscript(_:)' is unavailable: cannot subscript String with an Int (Swift 5)

I have only found one answer to this here. My problem is I am not using Characters except for that's what a String is - a collection of characters. I tried making this a String viz; let name ...
David's user avatar
  • 333
-4 votes
1 answer
811 views

What are lists in Swift, and how can I use subscripts with a list? [closed]

The Swift Programming Guide (Swift 5.1 Edition) says that subscripts can be used to access members of “a collection, list, or sequence.” Collection and Sequence are defined protocols in Swift and are ...
Mark Cowan's user avatar
-4 votes
1 answer
254 views

How to fix vector subscript out of range in c++

I'm trying to compare elements of the "coordinateList" vector with elements of "Buttons" vector and if four different if-statements are okay to pass them, increase 1 in "countList" vector. But, the ...
Lua's user avatar
  • 1
3 votes
2 answers
1k views

Replace subscript number in string

I have the following vector and I want to have the subscript numbers (e.g. ₆, ₂) to be replaced with 'normal' numbers. vec = c("C₆H₄ClNO₂", "C₆H₆N₂O₂", "C₆H₅NO₃", "C₉H₁₀O₂", "C₈H₈O₃") I could lookup ...
andschar's user avatar
  • 3,753
1 vote
0 answers
30 views

Difficulty using both greek letter and subscript in label

I am trying to create a y label that has both the Delta symbol and a subscript in it but am having problems combining the two. This is what I have for the label in my ggplot expression: y=expression(...
Abby's user avatar
  • 19
4 votes
1 answer
927 views

Swift subscript with argument label

Is it possible to create a subscript that can be invoked with explicit argument labels? struct MyType { subscript (label: Bool) -> String? { return nil } } let test = MyType() let ...
jeremyabannister's user avatar
0 votes
0 answers
259 views

How do I create subscripts in data point labels in R?

I am creating a scatter plot ans want to label the data points, giving them chemical salt names. How do I create subscripts of the numbers in the names of the data points (e.g. 2 in MgCl2)? The ...
Annemiek's user avatar
2 votes
1 answer
179 views

Fortran array access via vector subscripts, cpp equivalent

I am wondering whether there is a cpp equivalent to accessing array locations in fortran via indexes stored in other arrays I am novice to cpp but experienced in oop fortran. I am thinking about ...
user1407220's user avatar
0 votes
0 answers
251 views

UWP Win 10 XAML Super/Sub script rendering issues

I'm working on UWP app that has lots of text rendering, including some formulas and math equations. It's all fun and games until you bump into Superscript or Subscript parts of text with Cyrillic ...
Overrided's user avatar
  • 157
0 votes
1 answer
117 views

How do I get subscript in ggplot2 facet grid labels when I have two faceting variables?

I am trying to change one of the labels in my facet grid to contain some subscript text. I have been looking on stack overflow but none of the solutions work/I cannot understand how others are ...
Jacob D Parker's user avatar
0 votes
1 answer
178 views

Swift Type subscripts

In the Apple Language Guide for Swift 5.1 there is an example of Type Subscripts. enum Planet: Int { case mercury = 1, venus, earth, mars, jupiter, saturn, uranus, neptune static subscript(n: Int) -...
bhartsb's user avatar
  • 1,326
1 vote
1 answer
943 views

Add superscript and subscript exactly at the same X axis in SVG

I want to place superscript and subscript in the same place for a text, in SVG. This is a requirement in mathematical and chemical equations. There seems to be no option for such a requirement in SVg. ...
Velusamy Velu's user avatar
0 votes
1 answer
175 views

Double For loops in VBA, different subscripts

I've got a problem with nested loop in VBA. Algorithm that I need to execute looks like this: Option base 1 arr(4,2) i = 1 To 4 j = 2 To 100 i = 1, j = 2 If Cells(2, 1).Value = arr(1,1) Then ...
TheEditingify's user avatar
3 votes
2 answers
2k views

HTML Superscript & Subscript Issue

Adding superscript and subscript for a given text doesn't work as expected. However it works exactly as expected before the text. Chemical elements use superscripts and subscripts before and after an ...
Velusamy Velu's user avatar
1 vote
0 answers
54 views

Subscript out of bonds when applying mjca

I try to apply the mjca function (multiple correspondence analysis) from the ca package and I type in: mca_adjusted <- mjca(dataframe, supcol = 1, lambda = "adjusted") The supcol function is ...
trimmu's user avatar
  • 11
0 votes
1 answer
190 views

How can I print a subscript like E_{n} with ZPL II?

I want to send a String to the Zebra printer in which I have e.g. the energy E_{N} printed whereas N must be a subscript of E. I can send strings to the printer which are in a normal format (e.g. 'bla=...
Alex's user avatar
  • 11
1 vote
1 answer
666 views

Is there a way to make octave interpret strings in static text of uicontrol using TeX (Greek letters, subscripts, superscripts etc.)?

I am writing a GUI in GNU octave (5.1.0). It is supposed to read some input values, make some calculations, plot some graphs and write the results. Everything works well besides the unwanted fact that ...
Tomáš Hofer's user avatar
0 votes
1 answer
609 views

how to open pdf files in loop using vba macro

i got error out of range on lbound and uboud. please help. this are my codes. Its working on other macro i made. Error starts at ubound and lbound. when i run it, its resulting to subscript error. I ...
Matet Tarectecan's user avatar
-1 votes
1 answer
113 views

I need to make a program that takes the median of a list of numbers then finds the middle number [duplicate]

I have a problem that one of the things i need to include is a subscript of median, but i have no clue what that means I have tried most things but again i have no clue what subscript of median means....
Chandlor Stiffler's user avatar
0 votes
1 answer
192 views

Mainscript executes subscripts in a new terminal window

"Debian 9 64x - LXDE" I try to create an install script in bash. Lets assume i want to install samba. I call from the mainscript the install script for samba \folder\samba.sh. The script samba.sh ...
int3g3r's user avatar
  • 15
17 votes
8 answers
42k views

how to add subscript(or superscript) in notion block?

i am new in using notion as a notebook.Before this,i use oneNote instead,because i found that notion is more convinient in same ways.But one thing making me annoyed is that i can't add subscript(or ...
sayno's user avatar
  • 171
6 votes
1 answer
4k views

How to type subscripts in geom_text labels in ggplot

I have timeseries data plotted and separated by timepoints that I'd like to label with subscripts. Below is the code I'm using to generate the figure and timepoint labels. I'd like for the -1, 3 and 6 ...
user avatar

1 2 3
4
5
13